Email List: Xaustin-review-lX
[All Lists]

Defect in XSH mq_notify()

To: yyyyyyyyyyyyyyy@xxxxxxxxxxxxx
Subject: Defect in XSH mq_notify()
From: yyyyyyy@xxxxxxxxxx
Date: Mon, 12 Apr 2004 22:23:55 +0100 (BST)
        Defect report from : Ulrich Drepper , Red Hat, Inc.

(Please direct followup comments direct to yyyyyyyyyyyyyy@xxxxxxxxxxxxx)

@ page 788 line 25853 section mq_notify() comment {ud-mq-2}

Problem:

Edition of Specification (Year): 2003

Defect code :  1. Error

It is not specified what happens for a call like

  mq_notify(mq, NULL) 

where the process is not previously registered.  Is this an error?
Since the effect of call is exactly what the caller wants one could argue it is 
no problem.  At least one implementation returns EBUSY in this case which seems 
wrong from any angle.

Action:

After line 25853 add either:

  If the process is currently not registered nothing is done.

Or:

  If the process is currently not registered the call fails.

And add new error

  [EINVAL]   /notification/ is NULL and the process is currently not
             registered.

<Prev in Thread] Current Thread [Next in Thread>