Re: pid_t data type



"jason.cipriani@xxxxxxxxx" <jason.cipriani@xxxxxxxxx> writes:

On Mar 18, 5:48 am, Rainer Weikusat <rweiku...@xxxxxxxxxxx> wrote:
[snip]

Does it say somewhere that pid_t will never be a pointer type, or some
other type, like a float (which, while strange, is fine since it's
hidden behind the typedef)? If it can be, then the discussion of using
longs or whatever interchangeably with pid_t's is moot.

It needs to be a signed airthmetic type:

If pid is negative but not (pid_t)-1, sig will be sent to
all processes whose process group ID is equal to the abso-
lute value of pid and for which the process has permission
to send a signal.

Since it needs to be used in comparisons it can't really be float...

Casper
--
Expressed in this posting are my opinions. They are in no way related
to opinions held by my employer, Sun Microsystems.
Statements on Sun products included here are not gospel and may
be fiction rather than truth.
.