]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Fix logic errors from 208746
authorJeff Peeler <jpeeler@digium.com>
Mon, 27 Jul 2009 01:18:31 +0000 (01:18 +0000)
committerJeff Peeler <jpeeler@digium.com>
Mon, 27 Jul 2009 01:18:31 +0000 (01:18 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@208923 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_iax2.c
main/translate.c

index a7f008f2b695112c3bca1ba989fc2b0a78b6a745..0bdc40176f4669d0da75a56518abaa315af7e842 100644 (file)
@@ -3722,7 +3722,7 @@ static enum ast_bridge_result iax2_bridge(struct ast_channel *c0, struct ast_cha
                return AST_BRIDGE_FAILED;
        }
        /* Put them in native bridge mode */
-       if ((!flags) & (AST_BRIDGE_DTMF_CHANNEL_0 | AST_BRIDGE_DTMF_CHANNEL_1)) {
+       if (!(flags & (AST_BRIDGE_DTMF_CHANNEL_0 | AST_BRIDGE_DTMF_CHANNEL_1))) {
                iaxs[callno0]->bridgecallno = callno1;
                iaxs[callno1]->bridgecallno = callno0;
        }
index e801e0e448712a720381215e95b09f68fe9ad0cc..5c92dee57229fca359ba799fff9eda88611eaeff 100644 (file)
@@ -920,7 +920,7 @@ unsigned int ast_translate_available_formats(unsigned int dest, unsigned int src
           destination format. */
        for (x = 1; src_audio && x < AST_FORMAT_MAX_AUDIO; x <<= 1) {
                /* if this is not a desired format, nothing to do */
-               if ((!dest) & x)
+               if (!(dest & x))
                        continue;
 
                /* if the source is supplying this format, then
@@ -946,7 +946,7 @@ unsigned int ast_translate_available_formats(unsigned int dest, unsigned int src
           destination format. */
        for (; src_video && x < AST_FORMAT_MAX_VIDEO; x <<= 1) {
                /* if this is not a desired format, nothing to do */
-               if ((!dest) & x)
+               if (!(dest & x))
                        continue;
 
                /* if the source is supplying this format, then