diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2015-10-08 12:33:06 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2015-10-08 12:33:06 +0200 |
commit | 24feb9f37f302c006ba51502da817325200e74d0 (patch) | |
tree | d4451782449e5fcbae9cbe3778c51a8c6cb3c36d /backend/rts8891.c | |
parent | 76b69ebb381d40458339c9940135740797cbd2d4 (diff) | |
parent | cfd27ef2ad8b005fd47ab41ef29b71d9e3d48201 (diff) |
Merge tag 'upstream/1.0.25'
Upstream version 1.0.25
Diffstat (limited to 'backend/rts8891.c')
-rw-r--r-- | backend/rts8891.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/backend/rts8891.c b/backend/rts8891.c index d86347b..bdb4011 100644 --- a/backend/rts8891.c +++ b/backend/rts8891.c @@ -2212,7 +2212,13 @@ sane_close (SANE_Handle handle) /* switch off lamp and close usb */ if (dev->conf.allowsharing == SANE_TRUE) { - sanei_usb_claim_interface (dev->devnum, 0); + SANE_Status status = sanei_usb_claim_interface (dev->devnum, 0); + if (status != SANE_STATUS_GOOD) + { + DBG (DBG_warn, "sane_close: cannot claim usb interface: %s\n", + sane_strstatus(status)); + DBG (DBG_warn, "sane_close: continuing anyway\n"); + } } set_lamp_state (session, 0); sanei_usb_close (dev->devnum); @@ -3197,14 +3203,6 @@ find_origin (struct Rts8891_Device *dev, SANE_Bool * changed) return status; } - if (status != SANE_STATUS_GOOD) - { - free(image); - free(data); - DBG (DBG_error, "find_origin: failed to wait for data\n"); - return status; - } - if (DBG_LEVEL > DBG_io2) { write_gray_data (data, "find_origin.pnm", width, height); |