[asterisk-bugs] [Asterisk 0015617]: [patch] crash in LOCAL() if Gosub stack is allocated but empty
Asterisk Bug Tracker
noreply at bugs.digium.com
Thu Jul 30 14:45:14 CDT 2009
The following issue has been SUBMITTED.
======================================================================
https://issues.asterisk.org/view.php?id=15617
======================================================================
Reported By: rain
Assigned To: tilghman
======================================================================
Project: Asterisk
Issue ID: 15617
Category: Applications/app_stack
Reproducibility: always
Severity: minor
Priority: normal
Status: assigned
Asterisk Version: Older 1.6.0
Regression: No
SVN Branch (only for SVN checkouts, not tarball releases): N/A
SVN Revision (number only!):
Request Review:
======================================================================
Date Submitted: 2009-07-30 14:45 CDT
Last Modified: 2009-07-30 14:45 CDT
======================================================================
Summary: [patch] crash in LOCAL() if Gosub stack is allocated
but empty
Description:
If the Gosub stack is allocated but empty (e.g. outside of a Gosub, but
after a previous call to Gosub on the current channel), local_read() will
crash because it blindly dereferences frame = AST_LIST_FIRST(oldlist),
which will be NULL.
The attached patch (against trunk) ensures that the stack is not empty in
local_read() and deallocates the datastore in return_exec() if the stack is
empty. The latter might not be desirable, but each change is in a separate
hunk in the patch should you only want one of them. The patch applies
cleanly against 1.6.x as well.
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
2009-07-30 14:45 rain New Issue
2009-07-30 14:45 rain Status new => assigned
2009-07-30 14:45 rain Assigned To => tilghman
2009-07-30 14:45 rain Asterisk Version => Older 1.6.0
2009-07-30 14:45 rain Regression => No
2009-07-30 14:45 rain SVN Branch (only for SVN checkouts, not tarball
releases) => N/A
======================================================================
More information about the asterisk-bugs
mailing list