Browse code

bug_fix: callbacks introduced to _reply too

Jiri Kuthan authored on 09/09/2002 03:35:53
Showing 1 changed files
... ...
@@ -196,6 +196,15 @@ static int _reply( struct cell *trans, struct sip_msg* p_msg,
196 196
 	/* do UAC cleanup procedures in case we generated
197 197
 	   a final answer whereas there are pending UACs */
198 198
 	if (code>=200) {
199
+		if (trans->local) {
200
+			DBG("DEBUG: local transaction completed from _reply\n");
201
+			callback_event( TMCB_LOCAL_COMPLETED, trans, FAKED_REPLY, code );
202
+			if (trans->completion_cb) 
203
+				trans->completion_cb( trans, FAKED_REPLY, code, 0 /* empty param */);
204
+		} else {
205
+			callback_event( TMCB_REPLY, trans, FAKED_REPLY, code );
206
+		}
207
+
199 208
 		cleanup_uac_timers( trans );
200 209
 		if (trans->is_invite) cancel_uacs( trans, cancel_bitmap );
201 210
 		set_final_timer(  trans );