Closed meiser79 closed 3 years ago
I think I understand why this happens (though IMHO the brother backend should handle this situation more gracefully). It will take me a few days (or weeks) before I have time to fix it, I will let you know.
I added a call to sane_cancel() that might have been missing. The SANE docs are not very clear about how to properly abort a scan. Maybe it works for you now -- it works for me with the genesys backend as it did before.
Sorry to say, the behaviour is still the same. AirSane sends a lot of "503 Service Unavailable".
I did not get similar bug reports from users with other backends, so I tend to see this as a bug in the brother4 backend. AirSane closes the backend properly, this should not leave the device in an undefined state.
I can stop a preview scan in xscanimage, and afterwards start a new preview scan (scanner connected via saned). So I have the impression that the issue is not brother4 backend related.
Whatever the reason, I'm sorry to say I have no idea how to fix this issue.
When using the SANE airscan backend with xscanimage, cancelling the preview scan also brings the scanner in the undefined state.
The debug output shows:
Error: Failed restore value of option tl-x: Invalid argument.
Error: Failed restore value of option tl-y: Invalid argument.
Error: Failed restore value of option br-x: Invalid argument.
Error: Failed restore value of option br-y: Invalid argument.
Here's the full debug log: xscanimage-airscan-backend.txt
Maybe this helps.
Hi,
while AIC scanned the preview, I pressed the cancel button. After this, I couldn't scan anymore. I had to power-off and power-on my scanner. I own a Brother DCP-1510 which uses the brother4 SANE driver (deb package version 0.4.9-1), running on Ubuntu 20.04.
The log shows which indicates that airsaned "hangs" at _saneopen(brother4:bus1;dev2)
Thanks in advance for having a look. Best regards, meiser