From: Bastian Dehn Date: Mon, 26 Feb 2024 18:50:08 +0000 (+0100) Subject: return no docs when all scanned X-Git-Tag: v1.0.0^2~174 X-Git-Url: https://gitweb.hhaalo.de/?a=commitdiff_plain;h=5874715e3e781910229da83396c2bd8c5a60bdaa;p=sane-kds-s2000w-net.git return no docs when all scanned --- diff --git a/src/kds_s2000w_net.c b/src/kds_s2000w_net.c index 9f176ca..e5bd656 100644 --- a/src/kds_s2000w_net.c +++ b/src/kds_s2000w_net.c @@ -179,6 +179,11 @@ SANE_Status _sane_kds_s2000w_net_start(SANE_Handle handle) h->current_metadata->is_last = 0; kds_s2000w_handler_start_scan(h); } + + if (h->current_scan_status->complete_scanned + && h->current_scan_status->current_image_number >= h->current_scan_status->downloaded_images) + return SANE_STATUS_NO_DOCS; + return SANE_STATUS_GOOD; }