On Tue, 26 Feb 2002, Ralf Wildenhues wrote:
> Some questions and comments regarding splint lib files > (as of splint-3.0.1.6): > > fchmod is undeclared in unix.h, cf. > http://www.opengroup.org/onlinepubs/007908799/xsh/fchmod.html > A possible declaration could IMHO be > > int fchmod (int fildes, mode_t mode) > /*@modifies fileSystem, errno@*/ ; > > Okay, this is included now, along with the other missing function is unistd.h. > crypt is not declared in unix.h, cf. > http://www.opengroup.org/onlinepubs/007908799/xsh/crypt.html > Possible declaration: > > /*@dependent@*/ char *crypt (const char *key, const char *salt) > /*@modifies internalState@*/ ; > crypt can set errno and return null, so here's what we have now: /*@dependent@*/ /*@null@*/ char *crypt(const char *, const char *) /*@modifies errno, internalState@*/ ; > > In posix.h, waitpid's options WNOHANG and WUNTRACED are undefined. They > are mentioned in > http://www.opengroup.org/onlinepubs/007908799/xsh/wait.html , so maybe > they should be added. I'm not sure if they are mentioned in POSIX as I > am lacking a standard document, maybe they should be defined in unix.h > instead - maybe somebody with access to a standard document could check > this? > I've added them now. > > In standard.h and stdio.h, tmpfile should return dependent, similar to > fopen. freopen should return dependent, too, but I'm not sure if rather > its last argument should be declared as returned. Okay, they are now /*@dependent@*/ /*@null@*/ FILE *tmpfile (void) /*@modifies fileSystem, errno@*/ ; /*@dependent@*/ /*@null@*/ FILE *freopen (char *filename, char *mode, FILE *stream) /*@modifies *stream, fileSystem, errno@*/ ; > > In posix.h and unix.h, readdir should return dependent, similar to fopen. > Yep. > > BTW, since the time the lclint-interest started being moderated, I have > only received messages authored by David Evans. Is this the proposed > way to go, reading the original messages only by quotation in the > replies? > I believe this is fixed now, and messages bounce to the list properly. We're working on making unix.h consistent with the Unix Single Specification Version 2. A more correct version is in the CVS development code now, but there are still some files to go before we will have a complete specification. --- Dave