diff --git a/ChangeLog b/ChangeLog index f49087d50..eb4a9f289 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2005-10-05 Mattias Ellert + + * backend/microtek2.c: Off-by-one error + 2005-10-03 Henning Meier-Geinitz * AUTHORS acinclude.m4 configure configure.in backend/Makefile.in diff --git a/backend/microtek2.c b/backend/microtek2.c index d468613d9..0e2a079e7 100644 --- a/backend/microtek2.c +++ b/backend/microtek2.c @@ -3576,7 +3576,7 @@ sane_get_option_descriptor(SANE_Handle handle, SANE_Int n) DBG(255, "sane_get_option_descriptor: handle=%p, sod=%p, opt=%d\n", (void *) handle, (void *) ms->sod, n); - if ( n < 0 || n > NUM_OPTIONS ) + if ( n < 0 || n >= NUM_OPTIONS ) { DBG(30, "sane_get_option_descriptor: invalid option %d\n", n); return NULL;