comparison mcabber/src/jabglue.c @ 409:82064124324d

Fix a SIGPIPE issue when connecting to the server This change fixes a SIGPIPE when cw_nb_connect() is called too fast after make_nb_netsocket(). In this case getsockopt() reports a wrong value (no error) and the first jab_send_raw() in jconn.c gets a SIGPIPE. The delay in jabglue.c can then be removed.
author Mikael Berthe <mikael@lilotux.net>
date Sat, 27 Aug 2005 22:20:03 +0200
parents 73433860665c
children d35050efb5ac
comparison
equal deleted inserted replaced
408:73433860665c 409:82064124324d
194 usleep(10000); 194 usleep(10000);
195 return; 195 return;
196 } 196 }
197 197
198 if (jc && jc->state == JCONN_STATE_CONNECTING) { 198 if (jc && jc->state == JCONN_STATE_CONNECTING) {
199 usleep(150000);
200 jab_start(jc); 199 jab_start(jc);
201 return; 200 return;
202 } 201 }
203 202
204 jab_poll(jc, 50); 203 jab_poll(jc, 50);