Philippe Mathieu-Daudé bf78fb1c1b usb: correctly handle Zero Length Packets
USB Specification Revision 2.0, §5.5.3:
  The Data stage of a control transfer from an endpoint to the host is complete when the endpoint does one of the following:
  • Has transferred exactly the amount of data specified during the Setup stage
  • Transfers a packet with a payload size less than wMaxPacketSize or transfers a zero-length packet"

hw/usb/redirect.c:802:9: warning: Declared variable-length array (VLA) has zero size
        uint8_t buf[size];
        ^~~~~~~~~~~ ~~~~

Reported-by: Clang Static Analyzer
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-id: 20180604151421.23385-2-f4bug@amsat.org
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2018-06-12 12:07:02 +02:00
..
2018-06-04 10:15:16 +01:00
2018-06-04 10:15:16 +01:00
2018-06-04 10:15:16 +01:00
2018-06-08 13:15:33 +01:00
2018-06-04 12:54:00 +01:00
2018-06-08 13:15:32 +01:00
2018-06-01 18:24:16 +01:00
2016-01-29 15:07:25 +00:00
2018-06-01 18:24:16 +01:00
2018-06-04 10:15:16 +01:00
2018-06-04 10:15:16 +01:00
2018-03-02 13:45:50 -06:00
2018-06-01 18:24:16 +01:00
2018-06-01 15:14:31 +02:00