[sane-devel] Fwd: Closing file descriptors opened in sane_get_devices (was Re: [epson2] leaking file descriptors)

Olaf Meeuwissen olaf.meeuwissen at avasys.jp
Sun Sep 1 23:54:23 UTC 2013


m. allan noah writes:

> On Thu, Aug 29, 2013 at 3:53 AM, Olaf Meeuwissen
> <olaf.meeuwissen at avasys.jp> wrote:
>> Olaf Meeuwissen writes:
>>
>>
>> So my question really boils down to whether backends must/should close
>> any file descriptors opened as a result of calling sane_get_devices().
>>
>> Thoughts, anyone?
>
> My backends closes the device at the end of their attach routine, for
> exactly this reason. I would say that backends must do this, but I
> doubt that is written down anywhere for authors to read.

I'd expect such information with the specification for sane_get_devices.
There is none and as far as I can remember there is nothing elsewhere
either.

Hope this helps,
-- 
Olaf Meeuwissen, LPIC-2           FLOSS Engineer -- AVASYS CORPORATION
FSF Associate Member #1962               Help support software freedom
                 http://www.fsf.org/jf?referrer=1962



More information about the sane-devel mailing list