diff options
author | Joshua Colp <jcolp@digium.com> | 2007-10-01 15:57:04 +0000 |
---|---|---|
committer | Joshua Colp <jcolp@digium.com> | 2007-10-01 15:57:04 +0000 |
commit | 5ae00a58b341686d4913f5458dacf07fe83ad808 (patch) | |
tree | ffbbed8c67b70c458cc3d8f9dffe564d6307dcf5 /channels | |
parent | 7a542a0a392c2e376811ad4064cdc6609acac827 (diff) |
Check to make sure a structure pointer is non-NULL before touching it... crashing is bad, mmmk?
(closes issue #10831)
Reported by: eliel
Patches:
chan_sip.c.patch uploaded by eliel (license 64)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@84176 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels')
-rw-r--r-- | channels/chan_sip.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c index c671b62bd..2bd516b8d 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -18912,7 +18912,7 @@ static char *sip_reload(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a ast_verbose("Previous SIP reload not yet done\n"); else { sip_reloading = TRUE; - sip_reloadreason = a->fd ? CHANNEL_CLI_RELOAD : CHANNEL_MODULE_RELOAD; + sip_reloadreason = (a && a->fd) ? CHANNEL_CLI_RELOAD : CHANNEL_MODULE_RELOAD; } ast_mutex_unlock(&sip_reload_lock); restart_monitor(); |