WG15 Defect Report Ref: 9945-1-amd1-06
Topic: semaphores


This is an approved interpretation of 9945-1-amd1-1993.

.

Last update: 1997-05-20


								9945-1-amd1-93  #6

 _____________________________________________________________________________

	Topic:                semaphores
	Relevant Sections:    11.2.3.2, page 222, lines 110-118

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

	From: Venkatesh Radhakrishnan <rven@cup.hp.com>
	Date: Tue, 20 Feb 1996 16:26:09 PST

------------------------------------------------------------------------------

Section 11.2.3.2, page 222, lines 110-118

What are the meanings of read and write permissions with respect to
semaphores? Is there a method of opening an existing semaphore for
O_RDONLY or O_RDWR or O_WRONLY?

What is the effect of calling sem_wait, sem_trywait or sem_post on a
semaphore which was created with read-only permission? Write-only
permission?

The standard does not specify a behavior if the semaphore was not
created with both read and write permissions. Should the post and
wait operations require both read/write access since this is both
a read and write operation? There is no error return for this
situation.



Interpretation response
------------------------
The standard is clear: only the the O_CREAT and O_EXCL flags have a defined
interpretation.  The other flags are unspecified and a strictly conforming
application will not use them.  Any usage or interpretations of the
flags by an implementation would be an extension.  


Rationale
-------------
None.
Forwarded to Interpretations group: Mar 7 1996
Finalised: April 11th 1996