]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[usb] Use correct length for memcpy()
authorMichael Brown <mcb30@ipxe.org>
Wed, 22 Mar 2017 12:14:57 +0000 (14:14 +0200)
committerMichael Brown <mcb30@ipxe.org>
Wed, 22 Mar 2017 12:14:57 +0000 (14:14 +0200)
Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/drivers/bus/usb.c

index cad26c77b87acfeed11bfee7a1f3eb6f6c9acf65..bd2a446be0d205ddb8e8883a5f4b3b07d9f2828c 100644 (file)
@@ -1005,8 +1005,8 @@ static int usb_describe ( struct usb_device *usb,
                }
 
                /* Describe function */
-               memcpy ( &desc->class, &association->class,
-                        sizeof ( desc->class ) );
+               memcpy ( &desc->class.class, &association->class,
+                        sizeof ( desc->class.class ) );
                desc->count = association->count;
                for ( i = 0 ; i < association->count ; i++ )
                        interfaces[i] = ( first + i );