mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-14 20:45:47 +00:00
Don't crash if the twain device name is null.
This commit is contained in:
parent
54a2891d33
commit
abe2c5811b
|
@ -185,7 +185,10 @@ TW_UINT16 TWAIN_IdentityGetNext (pTW_IDENTITY pOrigin, TW_MEMREF pData)
|
|||
|
||||
TRACE("DG_CONTROL/DAT_IDENTITY/MSG_GETNEXT\n");
|
||||
|
||||
if (device_list && device_list[DSM_currentDevice])
|
||||
if (device_list && device_list[DSM_currentDevice] &&
|
||||
device_list[DSM_currentDevice]->name &&
|
||||
device_list[DSM_currentDevice]->vendor &&
|
||||
device_list[DSM_currentDevice]->model)
|
||||
{
|
||||
pSourceIdentity->Id = DSM_sourceId ++;
|
||||
strcpy (pSourceIdentity->ProductName, device_list[DSM_currentDevice]->name);
|
||||
|
|
Loading…
Reference in a new issue