]> gitweb.hhaalo.de Git - sane-kds-s2000w-net.git/commitdiff
fix set highes dpi option
authorBastian Dehn <hhaalo@arcor.de>
Mon, 27 Oct 2025 15:07:11 +0000 (16:07 +0100)
committerBastian Dehn <hhaalo@arcor.de>
Mon, 27 Oct 2025 15:07:11 +0000 (16:07 +0100)
src/kds_s2000w_handler_opts.c

index 898fdcdb102a6113b49d709370c9d1b34acc8e93..144de49fb60fb718d9c573204e7b3c3ae9f0295f 100644 (file)
@@ -206,7 +206,7 @@ bool _kds_s2000w_opts_validate(SANE_Option_Descriptor* descriptor, const void* v
 
        if (descriptor->constraint_type == SANE_CONSTRAINT_WORD_LIST) {
                const int32_t* int_value = (const int32_t*) value;
-               for (int32_t i = 1; i < descriptor->constraint.word_list[0]; i++) {
+               for (int32_t i = 1; i <= descriptor->constraint.word_list[0]; i++) {
                        if (*int_value == descriptor->constraint.word_list[i])
                                return true;
                }