Some parts of SANE used __FUNCTION__ while other parts used __func__.
Now, __func__ is used consistently throughout the SANE sources. This
fixes all occurrences of the following GCC warning:
warning: ISO C does not support '__FUNCTION__' predefined identifier
Various parts of SANE introduced their own compatibility macros for
old compilers that don't support __func__. Most of these definitions
are identical or have minor differences. This patch replaces them
with a single instance in the central header file for backends.
Up to now, on failure the sanei_magic_rotate function returned a
success status. This fixes the following GCC warning:
warning: variable 'ret' set but not used
The line variable is not (and cannot be) declared 'const'. The string
variable points to a location in line, hence it is safe to cast away
'const'ness of the sanei_config_skip_whitespace() return value.
Sample code that mimicks the offending code gave different run-time
results when compiled with gcc-4.9.2 and clang-3.5.0. Rewriting the
sample code so that results matched gcc-4.9.2 for both compilers was
used to determine how to "fix" the offending statement.
This commit adds support for (slide) scanners based
on Pacific Image Electronics (PIE) oem scan hardware.
It is known to match the following USB scanners
PIE PowerSlide 3600 Untested
PIE PowerSlide 3650 Untested
PIE PowerSlide 4000 Untested
PIE PowerSlide 5000 Untested
Reflecta CrystalScan 7200 Untested
Reflecta ProScan 7200 Untested
Reflecta DigitDia 4000 Untested
Reflecta DigitDia 5000 Untested
Reflecta DigitDia 6000 Ok
The backend is based on work by Jan Vleeshouwers and Michael Rickmann.
Special thanks to Stéphane Voltz for the code review.
Add pieusb to backend/Makefile.am
Add pieusb to doc/Makefile.am
Add missing sanei/sanei_ir.c, sanei/sanei_ir.h, adapt Makefile.am
configure.ac: Add 'pieusb' to ALL_BACKENDS
ChangeLog: Add pieusb as new backend
Mark infrared functions as internal: sane_ir_* -> sanei_ir_*
sanei/sanei_ir.c: fix memory leaks
pieusb: rename cmdGetMode and cmdSetScanHead
... to their sanei_pieusb_cmd_... equivalent
pieusb: rename definition_list_head to pieusb_definition_list_head
Add pieusb to AUTHORS
pieusb: copyright 2012-2015
pieusb: don't include sanei_thread.h
add calls to sanei_usb_set_altinterface in sanei_usb_close and
sanei_usb_clear_halt- hopefully work around USB3/xhci problems
in Linux. Also, remove some unused code, and fix debug messages.
This follows up on earlier USB3 fixes. It only addresses libusb-1.0
because there is no convenience API for libusb-0.1 to get the current
configuration.
This fixes USB3 issues for the epson and epson2 backends. Both these
backends already made sure to send an even number of reads and writes
but were affected nevertheless.
It also solves USB3 issues with the third party epkowa backend. This
one doesn't bother to ensure even counts of packets read and written.
It works fine when this fix is applied (and it no longer clears halts
w/o a stall condition). Note, there is no need to ensure even packet
counts.
libusb on my Linux box is returning EACCES error when invalid
permissions exist. Modify open to translate that into
SANE_STATUS_ECCESS_DENIED since that error description is
used for this case.
Modify sanei_usb_test.c to not treat access denied or busy
error codes as real failures since its expected to occur on
boxes that USB device is already claimed by another driver
and if that device uses default root only permissions.
Improving here means do not set LIBS/CFLAGS if library is not detected.
This prevents some unknown options based to ld when host is Linux and
target is mingw32/64. Further improvements are needed if one wants this
snmp support when cross compiling to really work.
Also, to make commit bisectable, updated all autofoo files using
'autoreconf -i -f' and repatching ltmain.sh.
Also, test-driver was missing from git repo but the Makefile.in
checked in expected it to exist.
- fixed a bug in sanei_constrain_value spotted by
viresh_shirol@yahoo.co.uk where range max was exceeded due to rounding
in quantization
- added test case for sane fixed values range