[sane-devel] a backend test

Karsten Festag karsten.festag@t-online.de
Wed, 10 Apr 2002 22:15:44 +0200


Hi Frank,

I've tested your tstbackend from 08.04.2001. It showed me
nicely some bugs in my microtek2 backend :-). But after
correcting some of them, I'm now at the following point:

karsten@coyote:~ > tstbackend -d microtek2:/dev/scanner -l 1
2>tst.log
tstbackend, Copyright (C) 2002 Frank Zago
tstbackend comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute
it
under certain conditions.

          TEST: init/exit
          using device microtek2:/dev/scanner
          TEST: open/close
          TEST: options consistency
FATAL ERROR : cannot set a settable option (status=Invalid
argument)
warnings: 0  error: 0  checks: 4945

In the logfile of the backend I see that the option
tstbackend is complaining about is not active:

[microtek2] sane_control_option: option 21; action 1
[microtek2] sane_control_option: option 21 not active

Therefore sane_control_option fails with SANE_STATUS_INVAL. 

In my opinion it is correct to return SANE_STATUS_INVAL if
the frontend tries to set an option that is not active. Am I
missing something?


Karsten