summaryrefslogtreecommitdiff
path: root/channels/sig_analog.c
diff options
context:
space:
mode:
authorRichard Mudgett <rmudgett@digium.com>2012-07-12 20:28:07 +0000
committerRichard Mudgett <rmudgett@digium.com>2012-07-12 20:28:07 +0000
commit9773d2351b692a1639e02a1b7025f06e2f7775b7 (patch)
treec8066efb3324a129062eef4af8ef5e8e45da32d7 /channels/sig_analog.c
parentc1354af599f12b8b15c35d23cfd665a37a095245 (diff)
Add missing ast_hangup() calls on some analog exception paths.
Make starting analog_ss_thread() or __analog_ss_thread() failure paths hangup the channel. ........ Merged revisions 370017 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 370025 from http://svn.asterisk.org/svn/asterisk/branches/10 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370037 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/sig_analog.c')
-rw-r--r--channels/sig_analog.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/channels/sig_analog.c b/channels/sig_analog.c
index eef043676..f40932f27 100644
--- a/channels/sig_analog.c
+++ b/channels/sig_analog.c
@@ -3886,6 +3886,7 @@ void *analog_handle_init_event(struct analog_pvt *i, int event)
ast_log(LOG_WARNING, "Cannot allocate new structure on channel %d\n", i->channel);
} else if (ast_pthread_create_detached(&threadid, NULL, __analog_ss_thread, i)) {
ast_log(LOG_WARNING, "Unable to start simple switch thread on channel %d\n", i->channel);
+ ast_hangup(chan);
}
}
ast_callid_threadstorage_auto_clean(callid, callid_created);
@@ -3912,6 +3913,7 @@ void *analog_handle_init_event(struct analog_pvt *i, int event)
ast_log(LOG_WARNING, "Cannot allocate new structure on channel %d\n", i->channel);
} else if (ast_pthread_create_detached(&threadid, NULL, __analog_ss_thread, i)) {
ast_log(LOG_WARNING, "Unable to start simple switch thread on channel %d\n", i->channel);
+ ast_hangup(chan);
}
}
ast_callid_threadstorage_auto_clean(callid, callid_created);