Hi,

I've written a C program which does following things when given its
desired inputs:

* Attaches signal handlers to SIGINT and SIGTERM signals.
* Creates a TCP/IPv4 socket
* Binds to the TCP/IPv4 address provided by user at command line.
* Creates a Mutex attribute with type "PTHREAD_MUTEX_NORMAL".
* Initializes a new Mutex with the newly created attribute
* Locks the mutex.
* Relocks the mutex and blocks.
* Destroys mutex, and mutex attribute.
* Closes the socket file descriptor

The SIGINT handler is used for unlocking mutex.

If I don't call "pthread_mutexattr_settype(&attr,
PTHREAD_MUTEX_NORMAL)", FreeBSD won't allow mutex to relock, which it
does to prevent deadlocks.

Following is the program:

- -- begin source --
/* bind.c */
#include <stdio.h>

#include <sys/types.h>
#include <sys/socket.h>

#include <arpa/inet.h>
#include <netinet/in.h>

#include <string.h>
#include <signal.h>
#include <pthread.h>

static pthread_mutex_t mutex;

void
ctrl_c_handler(int signo)
{
       fprintf(stderr, "Ctrl+C pressed.\n");
       pthread_mutex_unlock(&mutex);

}

int
main(int argc, char** argv)
{
       int fd, err;
       struct sockaddr_in addr;
       pthread_mutexattr_t attr;
       sig_t old;

       if(argc < 3)
       {
               fprintf(stderr, "Usage: %s [ipv4-address] [port]\n", argv[0]);
               return 0;
       }

       if((old = signal(SIGINT, &ctrl_c_handler)) == SIG_ERR)
       {
               perror("signal");
               return 5;
       }
       if((old = signal(SIGTERM, &ctrl_c_handler)) == SIG_ERR)
       {
               perror("signal");
               return 6;
       }

       if((fd = socket(AF_INET, SOCK_STREAM, 0)) == -1)
       {
               perror("socket");
               return 1;
       }

       addr.sin_family = AF_INET;
       addr.sin_addr.s_addr = inet_addr(argv[1]);
       addr.sin_port = htons(atoi(argv[2]));

#ifdef DEBUG
       printf("Binding to %s:%d\n", inet_ntoa(addr.sin_addr),
                       ntohs(addr.sin_port));
#endif

       if(bind(fd, (struct sockaddr*)&addr, sizeof(struct sockaddr_in)) ==
- -1)
       {
               perror("Error, binding to port");
               close(fd);
               return 2;
       }

       if(err = pthread_mutexattr_init(&attr))
       {
               fprintf(stderr, "Error initializing mutex attribute: %s\n",
                               strerror(err));
               close(fd);
               return 3;
       }

       if(err = pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_NORMAL))
       {
               fprintf(stderr, "Error setting type of mutex attribute: %s\n",
                               strerror(err));
               close(fd);
               return 3;
       }

       if(err = pthread_mutex_init(&mutex, &attr))
       {
               fprintf(stderr, "Error initializing mutex: %s\n", strerror(err));
               close(fd);
               return 3;
       }
       if(err = pthread_mutex_lock(&mutex))
       {
               fprintf(stderr, "Error locking mutex: %s\n", strerror(err));
               close(fd);
               return 3;
       }

       fprintf(stderr, "Press Ctrl+C to terminate\n");

       if(err = pthread_mutex_lock(&mutex))
       {
               fprintf(stderr, "Error locking mutex: %s\n", strerror(err));
               close(fd);
               return 3;
       }
       pthread_mutexattr_destroy(&attr);
       pthread_mutex_destroy(&mutex);

       close(fd);
       return 0;
}

- -- end source --

The program can be compiled with following command line:

- -- begin command line --
[EMAIL PROTECTED] sockets]$ cc -o bind bind.c -DDEBUG -pthread
- -- end command line --

And can be executed with following command line. In following command
line, 19245 is an unused TCP port:

- -- begin command line --
[EMAIL PROTECTED] sockets]$ ./bind 127.0.0.1 19245
Binding to 127.0.0.1:19245
Press Ctrl+C to terminate
- -- end command line --

The expected output from the program is that it should terminate when
Ctrl+C is pressed. On Debian 4 Etch (amd64), to compile the program,
I've to remove "if" block containing "pthread_mutexattr_settype(&attr,
PTHREAD_MUTEX_NORMAL)". And after that it executes as expected.
Whereas on FreeBSD, it waits for an infinite period. And to terminate
it, process has to be killed.

Any ideas what is wrong in the above program ? I've truss-ed it in
FreeBSD, some of the initial lines from "truss" output are pasted below:

- -- begin output --
mmap(0x0,7744,PROT_READ|PROT_WRITE,MAP_ANON,4294967295,0x0) =
34365136896 (0x800526000)
munmap(0x800526000,7744)                         = 0 (0x0)
__sysctl(0x7fffffffe910,0x2,0x80062e180,0x7fffffffe908,0x0,0x0) = 0
(0x0)
mmap(0x0,32768,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,
4294967295,0x0) = 34365136896 (0x800526000)
issetugid()                                      = 0 (0x0)
open("/etc/libmap.conf",O_RDONLY,0666)                 ERR#2 'No such file or
directory'
open("/var/run/ld-elf.so.hints",O_RDONLY,00)   = 3 (0x3)
read(3,"[EMAIL PROTECTED]"...,128) = 128 (0x80)
lseek(3,0x80,SEEK_SET)                           = 128 (0x80)
read(3,"/lib:/usr/lib:/usr/lib/compat:/u"...,199) = 199 (0xc7)
close(3)                                         = 0 (0x0)
access("/lib/libpthread.so.2",0)               = 0 (0x0)
open("/lib/libpthread.so.2",O_RDONLY,0400030560140) = 3 (0x3)
fstat(3,{mode=-r--r--r-- ,inode=70686,size=160552,blksize=4096}) = 0
(0x0)
read(3,"\^?ELF\^B\^A\^A\t\0\0\0\0\0\0\0"...,4096) = 4096 (0x1000)
mmap(0x0,1224704,PROT_READ|PROT_EXEC,MAP_PRIVATE|MAP_NOCORE,3,0x0) =
34366234624 (0x800632000)
mprotect(0x800654000,4096,PROT_READ|PROT_WRITE|PROT_EXEC) = 0 (0x0)
mprotect(0x800654000,4096,PROT_READ|PROT_EXEC)   = 0 (0x0)
mmap(0x800754000,16384,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_FIXED,
3,0x0) = 34367422464 (0x800754000)
mmap(0x800758000,20480,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_FIXED|
MAP_ANON,4294967295,0x0) = 34367438848 (0x800758000)
close(3)                                         = 0 (0x0)
access("/lib/libc.so.6",0)                     = 0 (0x0)
open("/lib/libc.so.6",O_RDONLY,0143)           = 3 (0x3)
fstat(3,{mode=-r--r--r-- ,inode=70674,size=1083208,blksize=4096}) = 0
(0x0)
read(3,"\^?ELF\^B\^A\^A\t\0\0\0\0\0\0\0"...,4096) = 4096 (0x1000)
mmap(0x0,2158592,PROT_READ|PROT_EXEC,MAP_PRIVATE|MAP_NOCORE,3,0x0) =
34367459328 (0x80075d000)
mprotect(0x800838000,4096,PROT_READ|PROT_WRITE|PROT_EXEC) = 0 (0x0)
mprotect(0x800838000,4096,PROT_READ|PROT_EXEC)   = 0 (0x0)
mmap(0x800938000,110592,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_FIXED,
3,0x0) = 34369404928 (0x800938000)
mmap(0x800953000,102400,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_FIXED|
MAP_ANON,4294967295,0x0) = 34369515520 (0x800953000)
close(3)                                         = 0 (0x0)
sysarch(0x81,0x7fffffffe980)                     = 0 (0x0)
mmap(0x0,544,PROT_READ|PROT_WRITE,MAP_ANON,4294967295,0x0) =
34365169664 (0x80052e000)
munmap(0x80052e000,544)                          = 0 (0x0)
mmap(0x0,7664,PROT_READ|PROT_WRITE,MAP_ANON,4294967295,0x0) =
34365169664 (0x80052e000)
munmap(0x80052e000,7664)                         = 0 (0x0)
mmap(0x0,45440,PROT_READ|PROT_WRITE,MAP_ANON,4294967295,0x800000000) =
34365169664 (0x80052e000)
munmap(0x80052e000,45440)                        = 0 (0x0)
getpid()                                         = 71525 (0x11765)
__sysctl(0x7fffffffe8e8,0x2,0x800757b50,0x7fffffffe8e0,0x0,0x0) = 0
(0x0)
__sysctl(0x7fffffffe8e8,0x2,0x7fffffffe8f0,0x7fffffffe8e0,0x0,0x0) = 0
(0x0)
__sysctl(0x7fffffffe8d0,0x2,0x800968858,0x7fffffffe8c8,0x0,0x0) = 0
(0x0)
readlink("/etc/malloc.conf",0x7fffffffe7e0,63)         ERR#2 'No such file or
directory'
issetugid()                                      = 0 (0x0)
mmap(0x0,4096,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,
4294967295,0x800000000) = 34365169664 (0x80052e000)
break(0x503000)                                  = 0 (0x0)
break(0x504000)                                  = 0 (0x0)
break(0x505000)                                  = 0 (0x0)
break(0x506000)                                  = 0 (0x0)
break(0x50a000)                                  = 0 (0x0)
break(0x50b000)                                  = 0 (0x0)
break(0x50d000)                                  = 0 (0x0)
break(0x50e000)                                  = 0 (0x0)
break(0x511000)                                  = 0 (0x0)
sigprocmask(SIG_BLOCK,SIGHUP|SIGINT|SIGQUIT|SIGKILL|SIGPIPE|SIGALRM|
SIGTERM|SIGURG|SIGSTOP|SIGTSTP|SIGCONT|SIGCHLD|SIGTTIN|SIGTTOU|SIGIO|
SIGXCPU|SIGXFSZ|SIGVTALRM|SIGPROF|SIGWINCH|SIGINFO|SIGUSR1|
SIGUSR2,0x0) = 0 (0x0)
sigprocmask(SIG_SETMASK,0x0,0x0)                 = 0 (0x0)
mmap(0x7fffffbff000,4096,PROT_NONE,MAP_ANON,4294967295,0x0) =
140737484156928 (0x7fffffbff000)
break(0x512000)                                  = 0 (0x0)
sysarch(0x81,0x7fffffffe8d0)                     = 0 (0x0)
sigprocmask(SIG_SETMASK,SIGHUP|SIGINT|SIGQUIT|SIGILL|SIGTRAP|SIGABRT|
SIGEMT|SIGFPE|SIGKILL|SIGBUS|SIGSEGV|SIGSYS|SIGPIPE|SIGALRM|SIGTERM|
SIGURG|SIGSTOP|SIGTSTP|SIGCONT|SIGCHLD|SIGTTIN|SIGTTOU|SIGIO|SIGXCPU|
SIGXFSZ|SIGVTALRM|SIGPROF|SIGWINCH|SIGINFO|SIGUSR1|SIGUSR2,0x0) = 0
(0x0)
sigaction(SIGHUP,0x0,{ SIG_DFL 0x0 ss_t })       = 0 (0x0)
sigaction(SIGINT,0x0,{ SIG_DFL 0x0 ss_t })       = 0 (0x0)
sigaction(SIGQUIT,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGILL,0x0,{ SIG_DFL 0x0 ss_t })       = 0 (0x0)
sigaction(SIGTRAP,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGABRT,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGEMT,0x0,{ SIG_DFL 0x0 ss_t })       = 0 (0x0)
sigaction(SIGFPE,0x0,{ SIG_DFL 0x0 ss_t })       = 0 (0x0)
sigaction(SIGKILL,0x0,{ SIG_DFL SA_RESTART ss_t }) = 0 (0x0)
sigaction(SIGBUS,0x0,{ SIG_DFL 0x0 ss_t })       = 0 (0x0)
sigaction(SIGSEGV,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGSYS,0x0,{ SIG_DFL 0x0 ss_t })       = 0 (0x0)
sigaction(SIGPIPE,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGALRM,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGTERM,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGURG,0x0,{ SIG_DFL SA_RESTART ss_t }) = 0 (0x0)
sigaction(SIGSTOP,0x0,{ SIG_DFL SA_RESTART ss_t }) = 0 (0x0)
sigaction(SIGTSTP,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGCONT,0x0,{ SIG_DFL SA_RESTART ss_t }) = 0 (0x0)
sigaction(SIGCHLD,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGTTIN,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGTTOU,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGIO,0x0,{ SIG_DFL SA_RESTART ss_t }) = 0 (0x0)
sigaction(SIGXCPU,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGXFSZ,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGVTALRM,0x0,{ SIG_DFL 0x0 ss_t })    = 0 (0x0)
sigaction(SIGPROF,0x0,{ SIG_DFL SA_RESTART ss_t }) = 0 (0x0)
sigaction(SIGWINCH,0x0,{ SIG_DFL 0x0 ss_t })     = 0 (0x0)
sigaction(SIGINFO,0x0,{ SIG_DFL SA_RESTART ss_t }) = 0 (0x0)
sigaction(SIGUSR1,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(SIGUSR2,0x0,{ SIG_DFL 0x0 ss_t })      = 0 (0x0)
sigaction(32,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(33,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(34,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(35,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(36,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(37,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(38,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(39,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(40,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(41,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(42,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(43,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(44,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(45,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(46,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(47,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(48,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(49,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(50,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(51,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(52,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(53,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(54,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(55,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(56,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(57,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(58,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(59,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(60,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(61,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(62,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(63,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(64,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(65,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(66,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(67,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(68,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(69,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(70,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(71,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(72,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(73,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(74,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(75,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(76,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(77,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(78,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(79,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(80,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(81,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(82,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(83,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(84,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(85,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(86,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(87,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(88,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(89,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(90,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(91,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(92,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(93,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(94,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(95,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(96,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(97,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(98,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(99,0x0,{ SIG_DFL SA_RESTART ss_t })    = 0 (0x0)
sigaction(100,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(101,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(102,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(103,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(104,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(105,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(106,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(107,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(108,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(109,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(110,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(111,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(112,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(113,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(114,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(115,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(116,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(117,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(118,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(119,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(120,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(121,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(122,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(123,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(124,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(125,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(126,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(127,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigaction(128,0x0,{ SIG_DFL SA_RESTART ss_t })   = 0 (0x0)
sigprocmask(SIG_SETMASK,0x0,0x0)                 = 0 (0x0)
sigaltstack(0x0,0x50d300)                        = 0 (0x0)
sigprocmask(SIG_BLOCK,SIGHUP|SIGINT|SIGQUIT|SIGKILL|SIGPIPE|SIGALRM|
SIGTERM|SIGURG|SIGSTOP|SIGTSTP|SIGCONT|SIGCHLD|SIGTTIN|SIGTTOU|SIGIO|
SIGXCPU|SIGXFSZ|SIGVTALRM|SIGPROF|SIGWINCH|SIGINFO|SIGUSR1|
SIGUSR2,0x0) = 0 (0x0)
sigprocmask(SIG_SETMASK,0x0,0x0)                 = 0 (0x0)
sigaction(SIGINT,{ 0x8006412b0 SA_RESTART|SA_SIGINFO ss_t },0x0) = 0
(0x0)
sigaction(SIGTERM,{ 0x8006412b0 SA_RESTART|SA_SIGINFO ss_t },0x0) = 0
(0x0)
socket(PF_INET,SOCK_STREAM,0)                    = 3 (0x3)
fstat(1,{mode=crw------- ,inode=54,size=0,blksize=4096}) = 0 (0x0)
break(0x513000)                                  = 0 (0x0)
ioctl(1,TIOCGETA,0x7fffffffe290)                 = 0 (0x0)
write(1,"Binding to 127.0.0.1:29023\n",27)     = 27 (0x1b)
bind(3,{ AF_INET 127.0.0.1:29023 },16)           = 0 (0x0)
Press Ctrl+C to terminate
write(2,"Press Ctrl+C to terminate\n",26)      = 26 (0x1a)
kse_release({60.000000000})                      ERR#22 'Invalid argument'
kse_release({60.000000000})                      ERR#22 'Invalid argument'
kse_release({60.000000000})                      ERR#22 'Invalid argument'
kse_release({60.000000000})                      ERR#22 'Invalid argument'
kse_release({60.000000000})                      ERR#22 'Invalid argument'
- -- end output --

As you can see, "kse_release" is invoked continously . Any ideas what
is wrong here ?

Thanks in advance,
Ashish Shukla

P.S. cross-posting ilug-dev mailing list.
- --
Ashish Shukla "Wah Java !!"
आशीष शुक्ल

weblog:   http://wahjava.wordpress.com/
webpages: http://wahjava.googlepages.com/

 ,= ,-_-. =.  | A: Yes.                                                    |
((_/)o o(\_)) | >Q: Are you sure?                                          |
 `-'(. .)`-'  | >>A: Because it reverses the logical flow of conversation. |
     \_/      | >>>Q: Why is top posting frowned upon?                     |

Attachment: pgpmZTXABogRT.pgp
Description: PGP signature

_______________________________________________
bsd-india mailing list
[email protected]
http://www.bsd-india.org/mailman/listinfo/bsd-india

Reply via email to