mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-08-13 17:38:59 +00:00
fix unclean shutdown
git-svn-id: http://svn.openzap.org/svn/openzap/trunk@693 a93c3328-9c30-0410-af19-c9cd2b2d52af
This commit is contained in:
@@ -219,11 +219,16 @@ static zap_status_t zap_span_destroy(zap_span_t *span)
|
||||
{
|
||||
zap_status_t status = ZAP_FAIL;
|
||||
|
||||
if (zap_test_flag(span, ZAP_SPAN_CONFIGURED) && span->zio && span->zio->span_destroy) {
|
||||
zap_log(ZAP_LOG_INFO, "Destroying span %u type (%s)\n", span->span_id, span->type);
|
||||
status = span->zio->span_destroy(span);
|
||||
zap_safe_free(span->type);
|
||||
zap_safe_free(span->dtmf_hangup);
|
||||
if (zap_test_flag(span, ZAP_SPAN_CONFIGURED)) {
|
||||
if (span->stop) {
|
||||
span->stop(span);
|
||||
}
|
||||
if (span->zio && span->zio->span_destroy) {
|
||||
zap_log(ZAP_LOG_INFO, "Destroying span %u type (%s)\n", span->span_id, span->type);
|
||||
status = span->zio->span_destroy(span);
|
||||
zap_safe_free(span->type);
|
||||
zap_safe_free(span->dtmf_hangup);
|
||||
}
|
||||
}
|
||||
|
||||
return status;
|
||||
|
Reference in New Issue
Block a user