HomeFreeBSD

Make ether_line really report an error when all input is invalid.

Description

Make ether_line really report an error when all input is invalid.

The previous code failed to return an error condition when the whole input
was invalid due to improper handling of the sscanf return value. Actually,
this failure was properly being caught by a test in
tools/regression/lib/libc/net/test-ether.t but was not noticed because
these tests are never run. (On my way to fixing that ;-)

The fix applied here resembles the implementation of ether_line in NetBSD
modulo the setting of an errno value (which is not documented as an
expectation in the manpage anyway).

Details

Provenance
jmmvAuthored on
Parents
rS263089: Fix description of WITHOUT_BMAKE's purpose.
Branches
Unknown
Tags
Unknown

Event Timeline