https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80400

Campbell <rlcamp.pdx at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rlcamp.pdx at gmail dot com

--- Comment #4 from Campbell <rlcamp.pdx at gmail dot com> ---
I hit this today in gcc 14.2.1, on

__attribute((packed)) struct ConfigDescriptor {
    uint8_t bLength;
    uint8_t bDescriptorType;
    uint16_t wTotalLength;
    uint8_t bNumInterfaces;
    uint8_t bConfigurationValue;
    uint8_t iConfiguration;
    uint8_t bmAttributes;
    uint8_t bMaxPower;
};

This was a particularly nefarious one to debug, as the kernel only validates
the lack of packing on this descriptor when plugged in through a USB hub, and
not directly, so the incorrect code was able to persist in production for
years...

Reply via email to