kopia lustrzana https://gitlab.com/sane-project/backends
Prevent segfault in case strndup cannot allocate memory
This complements 18f9e5598c
merge-requests/83/head
rodzic
f9eb32317a
commit
cadf5a9b1a
|
@ -1191,6 +1191,9 @@ sane_open (SANE_String_Const full_name, SANE_Handle * meta_handle)
|
|||
dev_name = "";
|
||||
}
|
||||
|
||||
if (!be_name)
|
||||
return SANE_STATUS_NO_MEM;
|
||||
|
||||
if (!be_name[0])
|
||||
be = first_backend;
|
||||
else
|
||||
|
|
Ładowanie…
Reference in New Issue