[sane-devel] Current TODO list

Henning Meier-Geinitz henning at meier-geinitz.de
Sat Aug 31 15:03:23 BST 2002


Hi,

On Fri, Aug 30, 2002 at 04:11:39PM -0700, David Paschal wrote:
> Henning Meier-Geinitz wrote:
> >   * All backends should check for TL_X < BR_X and TL_Y < BR_Y to
> >     avoid segfaults or even scanner damage. This should NOT be done
> >     in sane_control_option, it should be possible to temporary set
> >     TL_X > BR_X or TL_ > BR, otherwise it is hard for a frontend to
> >     set the correct values.
> Hi, Henning.  I take it sane_start is the correct place to check for
> this, right?  What is the correct response?  Perhaps it should return
> SANE_STATUS_INVAL, but the SANE standard doesn't list this as a possibility.

True, I didn't realize that SANE_STATUS_INVAL is missing in the list.
I'm using it nevertheless in sane_start. I'm returning that error code
also when a bad handle is used. I think I will put an addition to the
SANE standard on the TODO list.

> Another option, which is what I did in the hpoj backend, would be for the
> backend to keep shadow copies of the "effective" values for these options
> and swap the top and bottom values for X and Y if necessary.

I think that's even better but haven't tried in my backends yet.

Bye,
  Henning



More information about the sane-devel mailing list