WG15 Defect Report Ref: 9945-1-07
Topic: ignoring errors


This is an approved interpretation of 9945-1:1990.

.

Last update: 1997-05-20


                                                                9945-1-90 #7

        Classification: No change required



 _____________________________________________________________________________


	Topic:			ignoring errors
	Relevant Sections:	6.4.1.2, 6.4.2.2, B.6.4


Defect Report:
-----------------------

    In 6.4.1.2 Description [Read from a File], page 116, line 116:

	"If nbyte is zero, the read() function shall return zero and
	have no other results."
 
    In 6.4.2.2 Description [Write to a File], page 118, lines 190-191:
 
	"If nbyte is zero and the file is a regular file, the write()
	function shall return zero and have no other results."
 
    In B.6.4 Input and Output, page 266, lines 3433-3438:
 
	"POSIX.1 requires that no action be taken when nbyte is zero.
	This is not intended to take precedence over the detection of
	errors (such as invalid buffer pointers or file descriptors).
	This is consistent with the rest of POSIX.1, but the phrasing
	here could be misread to require the detection of the zero case
	before any other errors.  A value of zero is considered a
	correct value, for which the semantics are a no-op."
 
    Rather than being a misreading, the interpretation of 6.4.1.2 and
    6.4.2.2 that other errors shall be ignored seems to be the only
    possible interpretation permitted by the normative text.  Is the
    rationale in error?

WG15 response for ISO/IEC 9945-1:1990 (IEEE Std 1003.1-1990)
--------------------------------------------------

The text in 6.4.1.2 and 6.4.2.2 describes the behaviour only in the
absence of error conditions.  The rationale is therefore correct.

Rationale for Interpretation:
-----------------------------

By convention, the Description describes behaviour only in the
absence of error conditions, unless explicitly stated.  It is
expected that a future issue of the standard will clarify this.

The original intention in this case was to leave error checking 
optional.

 _____________________________________________________________________________