Friday, October 14, 2011

Prevent SIGPIPE from crashing the program

To do so, add following code to your program.
   signal( SIGPIPE, SIG_IGN ) ;

If debugging with GDB, GDB captures it and paused the process. To avoid this, run following command in gdb. For detailed information about handle, type "handle help" in gdb.
   handle SIGPIPE nostop print pass

No comments:

Check clients which connect to Mac OS X Wi-Fi Internet Sharing

arp -i bridge100 -a bridge100 may be different on your Mac OSX