From: Mark Spencer Date: Wed, 28 Jul 2004 18:38:29 +0000 (+0000) Subject: Fix "ZapOffHook" (bug #2161) X-Git-Tag: 1.0.0-rc2~77 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a57ad69b534a28b4fb583f6b53c3810cb35eddbe;p=thirdparty%2Fasterisk.git Fix "ZapOffHook" (bug #2161) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@3527 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_zap.c b/channels/chan_zap.c index c1e276fb21..ee1ea91832 100755 --- a/channels/chan_zap.c +++ b/channels/chan_zap.c @@ -8423,14 +8423,14 @@ static int action_zapdialoffhook(struct mansession *s, struct message *m) return 0; } p = find_channel(atoi(channel)); - if (!p->owner) { - astman_send_error(s, m, "Channel does not have it's owner"); - return 0; - } if (!p) { astman_send_error(s, m, "No such channel"); return 0; } + if (!p->owner) { + astman_send_error(s, m, "Channel does not have it's owner"); + return 0; + } for (i=0; i