From: Doug Bailey Date: Mon, 19 Jan 2009 18:22:44 +0000 (+0000) Subject: Get rid of magic number and replace with DAHDI_VMWI_NUMBER_MASK when X-Git-Tag: 1.6.2.0-beta1~415 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=42d4853f61b298b7d0aa13978caa1e90b164545e;p=thirdparty%2Fasterisk.git Get rid of magic number and replace with DAHDI_VMWI_NUMBER_MASK when determining the number of messages pending for MWI call git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@169325 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c index 17baf34ddd..2996cb158e 100644 --- a/channels/chan_dahdi.c +++ b/channels/chan_dahdi.c @@ -8258,10 +8258,10 @@ static void *do_monitor(void *data) } #else /* New DAHDI_VMWI ioctl supports upto 65535 messages*/ - if (res > 0xffff) { - res2 = (last->mwisendtype | 0xffff); + if (res > DAHDI_VMWI_NUMBER_MASK) { + res2 = (last->mwisendtype | DAHDI_VMWI_NUMBER_MASK); } else { - res2 = (last->mwisendtype | (res & 0xffff)); + res2 = (last->mwisendtype | (res & DAHDI_VMWI_NUMBER_MASK)); } res2 = ioctl(last->subs[SUB_REAL].dfd, DAHDI_VMWI, &res2); if (res2) {