ANNOUNCEMENT: Live Wireshark University & Allegro Packets online APAC Wireshark Training Session
April 17th, 2024 | 14:30-16:00 SGT (UTC+8) | Online

Wireshark-bugs: [Wireshark-bugs] [Bug 2822] New: Unusual use of a Boolean (Lint warning 514)

Date: Thu, 21 Aug 2008 11:17:41 -0700 (PDT)
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2822

           Summary: Unusual use of a Boolean (Lint warning 514)
           Product: Wireshark
           Version: SVN
          Platform: PC
               URL: http://www.wireshark.org/lists/wireshark-
                    dev/200808/msg00135.html
        OS/Version: All
            Status: NEW
          Severity: Major
          Priority: Low
         Component: Wireshark
        AssignedTo: wireshark-bugs@xxxxxxxxxxxxx
        ReportedBy: christopher.maynard@xxxxxxxxx


Build Information:
SVN 26033
--
When I ran lint on the Wireshark source code, it yielded some "Unusual use of a
Boolean" warnings.  The following 2 warnings seem to have merit:

1) epan\dissectors\packet-isup.c(2277):
I think this line:
        coding_standard = (tvb_get_guint8(parameter_tvb, offset)&&0x60)>>5;
should be:
        coding_standard = (tvb_get_guint8(parameter_tvb, offset)&0x60)>>5;

2) epan\dissectors\packet-smb2.c(513):
Similarly, I think this line:
        hash=((key->sesid>>32)&0xffffffff)+((key->sesid)&0xffffffff);
should be:
        hash=((key->sesid>>32)&0xffffffff)+((key->sesid)&0xffffffff);


-- 
Configure bugmail: https://bugs.wireshark.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.