Due to alignment requirements, libusb_hotplug_message might have
some padding bytes.
This change makes sure that these padding bytes are
initialised. Valgrind no longer complains about passing uninitialised
data to the write system call.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
libusb_hotplug_message message;
ssize_t ret;
+ memset(&message, 0, sizeof(message));
message.event = LIBUSB_HOTPLUG_EVENT_DEVICE_ARRIVED;
message.device = dev;
dev->attached = 1;
struct libusb_context *ctx = dev->ctx;
ssize_t ret;
+ memset(&message, 0, sizeof(message));
message.event = LIBUSB_HOTPLUG_EVENT_DEVICE_LEFT;
message.device = dev;
usbi_mutex_lock(&dev->lock);
-#define LIBUSB_NANO 10761
+#define LIBUSB_NANO 10762