From: erickson Date: Thu, 15 Jun 2006 18:34:14 +0000 (+0000) Subject: returning error code on disconnect X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=b77857c656f00b80461d60f64a771c4d514b8ddb;p=opensrf%2Fbjwebb.git returning error code on disconnect git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@736 9efc2488-bf62-4759-914b-345cdb29e865 --- diff --git a/src/libtransport/transport_session.c b/src/libtransport/transport_session.c index 82b5415..3de292f 100644 --- a/src/libtransport/transport_session.c +++ b/src/libtransport/transport_session.c @@ -374,6 +374,7 @@ void startElementHandler( if( strcmp( name, "stream:error" ) == 0 ) { ses->state_machine->in_error = 1; + ses->state_machine->connected = 0; osrfLogWarning( OSRF_LOG_MARK, "Received message from Jabber server" ); return; } diff --git a/src/utils/socket_bundle.c b/src/utils/socket_bundle.c index c865030..fc0f13a 100644 --- a/src/utils/socket_bundle.c +++ b/src/utils/socket_bundle.c @@ -597,7 +597,10 @@ int _socket_route_data_id( socket_manager* mgr, int sock_id) { if(node->endpoint == CLIENT_SOCKET ) status = _socket_handle_client_data(mgr, node); - if(status == -1) socket_remove_node(mgr, sock_id); + if(status == -1) { + socket_remove_node(mgr, sock_id); + return -1; + } return 0; }