www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1994/05/24/04:44:30

To: djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: Library problems
Date: Tue, 24 May 94 10:47:29 +0300
From: eliz AT is DOT elta DOT co DOT il

The following is a list of problems with the library as of 1.11maint5, which
I discovered and which were identified as ``bugs'' by DJ:

 1) The constants FILENAME_MAX, FOPEN_MAX and TMP_MAX are not defined in the
    header <stdio.h>, as they should be according to ANSI C.

 2) When spawnlp() is called with a name of a non-existing program, a message
    is printed saying "Invalid form size", and the function returns 34 instead
    of -1 as documented.  You are better off using spawnvp(), which works OK.

 3) readdir() sets errno to "No more files", when called after reading the last
    directory entry.  Existing U**X code expects errno to be left alone in this
    case, so that some programs might decide that an error occured while
    reading the directory.

 4) stat() and fstat() return inconsistent results for the same file.  The
    st_blksize field is reported as 4096 (correct) by fstat(), but stat()
    returns 512 (incorrect) in it.  stat() returns a unique value for each
    file in the st_ino field, whereas fstat() always returns 0 there.  (Beware
    programs that use this field to infer that files with the same st_ino are
    actually the same file.)

	Eli Zaretskii

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019