[sane-devel] Network connected scanner, i/o error if scanner is idle for longer then 40sec

Paul Newall p.newalls at ntlworld.com
Tue Dec 30 10:09:49 UTC 2014

I have been digging down into the code, and adding extra debug output.
In my network read function kodakaio_net_read it seems that poll(...) is 
indicating that there is data to read, but sanei_ tcp_read(..) then 
returns zero bytes.
If there was no data I'd expect poll to timeout, and if there was some 
data, sanei_ tcp_read should return it?
But this is the only network read code I have ever written in c so I am 
not too confident it is correct.


On 28/12/14 23:50, Paul Newall wrote:
> This was using xsane.
> If I close xsane and reopen it I can scan again.
> Paul
> On 28/12/14 20:40, m. allan noah wrote:
>> Are you using a long-running front-end like xsane, or multiple
>> invocations of something like scanimage?
>> allan
>> On Sun, Dec 28, 2014 at 3:24 PM, Paul Newall <p.newalls at ntlworld.com> 
>> wrote:
>>> I found, using the kodakaio backend, that leaving the scanner idle 
>>> between
>>> scans for more than around 40sec gives an i/o error when I try to scan
>>> again.
>>> I can scan any number of times with gaps of less than 30 sec between 
>>> scans
>>> without getting this error.
>>> Has anyone ever had a similar experience with any other backend?
>>> Does anyone have an idea what might be the cause?
>>> -- 
>>> sane-devel mailing list: sane-devel at lists.alioth.debian.org
>>> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel
>>> Unsubscribe: Send mail with subject "unsubscribe your_password"
>>>              to sane-devel-request at lists.alioth.debian.org

More information about the sane-devel mailing list