fix type conversion error

This commit is contained in:
luoliangyi 2023-07-31 10:46:33 +08:00
parent e1ea8bbc14
commit 343a17523b
1 changed files with 1 additions and 1 deletions

View File

@ -1768,7 +1768,7 @@ SANE_Option_Descriptor* hg_sane_middleware::get_option_descriptor(SANE_Handle h,
}
SANE_Status hg_sane_middleware::set_option(SANE_Handle h, const void* option, SANE_Action action, void* value, SANE_Int* after_do)
{
if ((IS_PTR_NUMBER(option) && (int)option == SANE_OPT_ID_DRIVER_LOG) ||
if ((IS_PTR_NUMBER(option) && (int)(long)option == SANE_OPT_ID_DRIVER_LOG) ||
(!IS_PTR_NUMBER(option) && strcmp((const char*)option, SANE_STD_OPT_NAME_DRIVER_LOG) == 0))
{
// omit value of 'h' ...