genesys: Fix use of uninitialized memory

merge-requests/52/head
Povilas Kanapickas 2019-04-23 00:05:33 +03:00
rodzic c9ebf2b560
commit 621c9799fe
1 zmienionych plików z 2 dodań i 0 usunięć

Wyświetl plik

@ -6014,6 +6014,8 @@ attach (SANE_String_Const devname, Genesys_Device ** devp, SANE_Bool may_wait)
return SANE_STATUS_INVAL;
}
memset(dev, 0x00, sizeof(Genesys_Device));
dev->file_name = strdup (devname);
if (!dev->file_name)
{