{
debug_printf(ALL, "kds_s2000w_handler_get_parameters");
handler* h = (handler*) handle;
- if (!h->current_scan_status->complete_scanned
- && h->current_scan_status->available_images <= 0) {
- _get_current_scan_status(h);
- }
-
if (h->current_scan_status->complete_scanned
&& h->current_scan_status->available_images <= 0) {
h->current_metadata->valid = 1;
return;
}
- _download_current_image(h);
- _get_current_metadata(h);
- _delete_current_image(h);
- h->current_scan_status->current_image_number++;
+ if (!h->current_scan_status->complete_scanned
+ && h->current_scan_status->available_images <= 0) {
+ _get_current_scan_status(h);
+ }
+
+ if (h->current_scan_status->available_images > 0) {
+ _download_current_image(h);
+ _get_current_metadata(h);
+ _delete_current_image(h);
+ h->current_scan_status->current_image_number++;
+ }
}
\ No newline at end of file