NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

toolchain/60432: sh(1) read return code documentation error



>Number:         60432
>Category:       toolchain
>Synopsis:       sh(1) read return code documentation error
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    toolchain-manager
>State:          open
>Class:          doc-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Jul 09 14:40:00 +0000 2026
>Originator:     Edgar Fu\ss
>Release:        NetBSD current
>Organization:
	Mathematisches Institut der Uni Bonn
>Environment:
System: N/A
Architecture: N/A
Machine: N/A
>Description:
	sh(1)'s manpage says

	The read built-in utility will indicate success (exit status 0)
	unless EOF, or a read error, is encountered on input, before
	encountering the delimiter, or having read max bytes.  In this
	case any data previously read will be assigned to the variables,
	as if the delimiter had been located at that point, and read will
	exit with status 1.  If there is a usage error (unknown option,
	etc) no variables will be altered, read will issue a diagnostic to
	standard error, and exit with a status greater than 1.

	kre says I/O errors will cause exit status >1.
	I'm inclined to beleive kre, not the manpage.
>How-To-Repeat:
	man 1 sh
>Fix:
	




Home | Main Index | Thread Index | Old Index