The last argument of dbm_open() should be a mode_t according to POSIX;
not an int. mode_t is smaller than an integer, as it's only 16 bits.
Adding jhb@: John, can such a change be made without breaking the ABI?
Differential D6650
Fix prototype of dbm_open(). ed on May 30 2016, 5:33 PM. Authored by Tags None Referenced Files
Details
The last argument of dbm_open() should be a mode_t according to POSIX; Adding jhb@: John, can such a change be made without breaking the ABI?
Diff Detail
Event TimelineComment Actions Just wondering ... perhaps the change is not very significant nowadays. At least on amd64, won't the compiler promote the 16 bit mode_t to an int anyways? Comment Actions It does that for in-language arithmetic, but I'm not sure what happens at the ABI level. Comment Actions I don't really know. kib@ might know? Given that it's libc, we can use symbol versioning if it does break the ABI. Comment Actions I believe all FreeBSD ABIs (and all Tier-1 ABIs definitely) would be fine with this change. |