From dfe28395b4ca957aae98925ac00421dcf4ee7c44 Mon Sep 17 00:00:00 2001 From: Bastian Dehn Date: Thu, 25 Jan 2024 19:13:19 +0100 Subject: [PATCH] add option descirptor count of options --- src/kds_s2000w_net.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/kds_s2000w_net.c b/src/kds_s2000w_net.c index 869e1a6..2f5a9c2 100644 --- a/src/kds_s2000w_net.c +++ b/src/kds_s2000w_net.c @@ -74,8 +74,19 @@ const SANE_Option_Descriptor* _sane_kds_s2000w_net_get_option_descriptor( { current_state* state = kds_s2000w_handler_current_state(); switch (option) { + case 0: + optionDescripor->name = ""; + optionDescripor->title = ""; + optionDescripor->desc = ""; + optionDescripor->type = SANE_TYPE_INT; + optionDescripor->unit = SANE_UNIT_NONE; + optionDescripor->size = sizeof(SANE_Int); + optionDescripor->cap = 0; + optionDescripor->constraint_type = SANE_CONSTRAINT_NONE; + optionDescripor->constraint.string_list = NULL; + break; default: - optionDescripor->name = "count of options"; + optionDescripor->name = ""; optionDescripor->title = "count of options"; optionDescripor->desc = "count of options"; optionDescripor->type = state->type; -- 2.39.5