Subject: Re: Why does mode_t need 32 bits?
To: Ross Harvey <ross@teraflop.com>
From: Chris G. Demetriou <cgd@pa.dec.com>
List: tech-kern
Date: 10/31/1997 15:12:38
> > But don't you _still_ have that same problem on a machine with 64-bit ints
> > when mode_t is u_int32_t?
>
> Except that there are no machines with 64 bit ints.
>
> At least, none of the risc or cisc micros do that. The lp64 scheme has its
> ups and downs, we may as well count on the ups and it _is_ a standard.
Sure, but it's still logically wrong to used fixed-size types when you
don't have to.
The 'correct' type in this case really is one which is "32 bits or
larger, as convenient for the machine." On all existing platforms,
that'd be 32-bits, so it wouldn't be a binary compatibility problem.
I seem to recall that some standard was going specify such types, but
I don't know what happened (or even which standard).
chris