Bug 104183 - mesa-17.3.0/src/broadcom/qpu/qpu_pack.c:171]: (error) Invalid memcmp() argument
Summary: mesa-17.3.0/src/broadcom/qpu/qpu_pack.c:171]: (error) Invalid memcmp() argument
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/vc4 (show other bugs)
Version: 17.3
Hardware: Other All
: medium normal
Assignee: Eric Anholt
QA Contact: Eric Anholt
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-09 20:27 UTC by dcb314
Modified: 2018-03-28 17:03 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description dcb314 2017-12-09 20:27:55 UTC
mesa-17.3.0/src/broadcom/qpu/qpu_pack.c:171]: (error) Invalid memcmp() argument nr 3. A non-boolean value is required.

Source code is

        return (packed_sig == 0 ||
                memcmp(sig, &v33_sig_map[0], sizeof(*sig) != 0));

Maybe better code

        return (packed_sig == 0 ||
                memcmp(sig, &v33_sig_map[0], sizeof(*sig)) != 0);
Comment 1 Emil Velikov 2018-03-28 17:03:55 UTC
Should be fixed with

commit 49e2586bfc7f806038bba7864dcff0c50fed1fe9
Author: Eric Anholt <eric@anholt.net>
Date:   Thu Dec 14 09:41:16 2017 -0800

    broadcom/vc5: Fix a typo in memcmp for sig unpack checking.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.