Wireshark mailing list archives
Re: About Dead Store in clang Analysis
From: Dirk Jagdmann <doj () cubic org>
Date: Thu, 24 Mar 2011 13:47:00 -0700
What it the official solution to fix this ? 1) Remove the code 2) Ignore this warning 3) Comment the code add a /* offset += 1; Remove Clang Dead increment */
I would say configure clang to not emit this warning. This idiom of adding a proto_item and then incrementing the offset is well proven throughout the code. Having that additional integer increment will not result in wasted CPU cycles. And if you have an incomplete dissector if the correct offset increment is used, you will not introduce a bug when adding additional proto_items. -- ---> Dirk Jagdmann ----> http://cubic.org/~doj -----> http://llg.cubic.org ___________________________________________________________________________ Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org> Archives: http://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
Current thread:
- About Dead Store in clang Analysis Alexis La Goutte (Mar 24)
- Re: About Dead Store in clang Analysis Stephen Fisher (Mar 24)
- Re: About Dead Store in clang Analysis Dirk Jagdmann (Mar 24)
- Re: About Dead Store in clang Analysis Chris Maynard (Mar 24)
- Re: About Dead Store in clang Analysis Jeff Morriss (Mar 24)
- Re: About Dead Store in clang Analysis John Sullivan (Mar 24)
- Re: About Dead Store in clang Analysis Dirk Jagdmann (Mar 24)
- Re: About Dead Store in clang Analysis Guy Harris (Mar 24)
- Re: About Dead Store in clang Analysis Guy Harris (Mar 24)