comparison src/gtkmain.c @ 10333:5eb81f349da7

[gaim-migrate @ 11540] Kevin, let me know if this doesn't take care of everything. Thanks for pointing these out! committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Thu, 09 Dec 2004 02:12:18 +0000
parents 8d42237564f6
children 5aa8ed1ec91e
comparison
equal deleted inserted replaced
10332:8d42237564f6 10333:5eb81f349da7
123 } 123 }
124 124
125 return ret; 125 return ret;
126 } 126 }
127 127
128 #if HAVE_SIGNAL_H
128 static void 129 static void
129 clean_pid(void) 130 clean_pid(void)
130 { 131 {
131 #ifndef _WIN32 132 #ifndef _WIN32
132 int status; 133 int status;
141 perror(errmsg); 142 perror(errmsg);
142 } 143 }
143 #endif 144 #endif
144 } 145 }
145 146
146 #if HAVE_SIGNAL_H
147 void 147 void
148 sighandler(int sig) 148 sighandler(int sig)
149 { 149 {
150 switch (sig) { 150 switch (sig) {
151 case SIGHUP: 151 case SIGHUP:
178 #endif 178 #endif
179 abort(); 179 abort();
180 break; 180 break;
181 case SIGCHLD: 181 case SIGCHLD:
182 clean_pid(); 182 clean_pid();
183 #if HAVE_SIGNAL_H
184 signal(SIGCHLD, sighandler); /* restore signal catching on this one! */ 183 signal(SIGCHLD, sighandler); /* restore signal catching on this one! */
185 #endif
186 break; 184 break;
187 default: 185 default:
188 gaim_debug_warning("sighandler", "Caught signal %d\n", sig); 186 gaim_debug_warning("sighandler", "Caught signal %d\n", sig);
189 gaim_connections_disconnect_all(); 187 gaim_connections_disconnect_all();
190 188