Skip to content

scanimage 1.0.32 broken

Environment:

openSUSE leap 15.3

Scanner ScanJet Pro 4500 fn1

scanimage and sane backend 1.0.32 from openSUSE repository

libsane-hpaio from openSUSE repository

skanlite from openSUSE repsitory

I am scanning via network, but it does not matter, the same problems occur when scanning via USB.

Scanning with skanlite works properly, none of the problems with scanimage are encountered with skanlite.

The problems with scanimage depend on --source, --resolution and --format

Corrupt TIFF image means, the following two errors show, when checking the format

TIFFReadDirectory: Warning, Bogus "StripByteCounts" field, ignoring and calculating from imagelength.

TIFFFillStrip: Read error on strip 0; got 16665600 bytes, expected 16695360.

I am always scanning with the command

scanimage --resolution XXX -x 210.000 -y 296.985 --mode Color --format=YYYY -- batch="filename-XXX-%03d.YYYY"

I vary the resolution XXX, the format YYYY, the filename and, most importantly

--source Flatbed --batch-count=1

--source ADF --batch-count=1

--source Duplex --batch-count=6

When I am scanning from ADF, I always insert three sheets of paper, even with --batch-count=1. When I am scanning from flatbed, I am inserting the title page of the same document.

Scanning with --source Flatbed --batch-count=1

Works with all formats (jpeg, tiff, png, pnm) and with a resolution of 600. scanimage does not crash, the images are not corrupt.

Scanning with --source ADF --batch-count=1

jpeg: scanning works with a resolution of 75 and 150. With a resolution of 200 and 600 scanimage crashes prematurely. One can view the corrupt images with okular and see, that the last 1 to 5 mm from the bottom of the document are missing.

The error message from scanimage is "Application transferred to few scan lines". The scanner shows "scanning" in its display for some time after scanimage crashed.

When scanimage crashes, the behaviour is always the same.

Note: There is no problem with --source Flatbed, and a resolution of 600, but with --source ADF --batch-count=1 scanimage crashes already with a resolution of 200 and format jpeg.

tiff: works with a resolution of 75. At a resolution of 150, 200 and 600 one page will be scanned, scanimage does not crash. This page can be viewed with, for instance gwenview, but the images are corrupt, showing the TIFF errors mentioned above.

png: works with a resolution of 75 and 150. At a resolution of 200 scanimage does not crash, but the images are corrupt, have the TIFF errors.

Scanning with --source Duplex --batch-count=6

jpeg: scanning of all six pages works with a resolution of 75 and 150. At a resolution of 200 scanimage crashes at the first page. Again, the last 2 to 5 mm are missing, when the corrupt image is viewed with okular.

tiff: scanning of all six pages works at a resolution of 75 and 150, no TIFF errors in the images. At a resolution of 200 and 600, all six pages are scanned as well, however, all images are corrupt having the two TIFF errors.

With skanlite, scanning of all six pages works fine with jpeg and tiff at a resolution of 600. No crash, no TIFF errors.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information