[sane-devel] run saned on ephemeral port

James Ring sjr at jdns.org
Sat Dec 5 17:18:04 GMT 2020


Hi all,

In developing jfreesane (pure Java client for saned,
https://github.com/sjamesr/jfreesane), I've found that it's useful to
run saned locally with a known configuration (e.g. 1 test device, 4
test devices, various test device configurations). This is complicated
by the fact that saned will only ever listen on sane-port as specified
in /etc/services, or 6566 if that entry is not present.

Would there be any interest in patching saned to accept a -p (port)
argument, which may be zero if an ephemeral port is desired? In the
ephemeral port case, the selected port is logged so the test may find
it.

I attached a proposed patch. What do you think?

Regards,
James
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sock.patch
Type: text/x-patch
Size: 3409 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/sane-devel/attachments/20201205/ed7029d7/attachment.bin>


More information about the sane-devel mailing list