[Freeswitch-svn] [commit] r12606 - freeswitch/trunk/src/mod/event_handlers/mod_erlang_event

FreeSWITCH SVN andrew at freeswitch.org
Sat Mar 14 16:53:32 PDT 2009


Author: andrew
Date: Sat Mar 14 18:53:32 2009
New Revision: 12606

Log:
Whoops


Modified:
   freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c

Modified: freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c
==============================================================================
--- freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c	(original)
+++ freeswitch/trunk/src/mod/event_handlers/mod_erlang_event/handle_msg.c	Sat Mar 14 18:53:32 2009
@@ -490,7 +490,7 @@
 					
 				}
 			}
-			/* release the lock returned by switch_core_locate_session */
+			/* release the lock returned by switch_core_session_locate */
 			switch_core_session_rwunlock(session);
 
 		} else {
@@ -579,14 +579,13 @@
 					ei_x_encode_atom(rbuf, "error");
 					ei_x_encode_atom(rbuf, "session_attach_failed");
 				}
+				/* release the lock returned by switch_core_session_locate */
+				switch_core_session_rwunlock(session);
 			} else {
 				ei_x_encode_tuple_header(rbuf, 2);
 				ei_x_encode_atom(rbuf, "error");
 				ei_x_encode_atom(rbuf, "badsession");
 			}
-			/* release the lock returned by switch_core_locate_session */
-			switch_core_session_rwunlock(session);
-
 		} else {
 			ei_x_encode_tuple_header(rbuf, 2);
 			ei_x_encode_atom(rbuf, "error");



More information about the Freeswitch-svn mailing list