Index: b/main/pbx.c
===================================================================
--- a/main/pbx.c
+++ b/main/pbx.c
@@ -7912,6 +7912,12 @@ static int pbx_outgoing_attempt(const ch
 			return -1;
 		}
 		if (locked_channel) {
+			/*  
+			 *  Avoid possible calling of destructor 
+			 *  of variable outgoing with locked channel
+			 */
+			ao2_ref(outgoing, -1);
+			outgoing = NULL;
 			ast_channel_lock(dialed);
 		}
 	}
