public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libfortran/31335]  New: Calls lstat(), stat() and fstat() in libgfortran should be protected by autoconf HAVE_{L,,F}STAT macros
@ 2007-03-24 11:02 fxcoudert at gcc dot gnu dot org
  2007-03-24 11:02 ` [Bug libfortran/31335] " fxcoudert at gcc dot gnu dot org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2007-03-24 11:02 UTC (permalink / raw)
  To: gcc-bugs

In libgfortran/intrinsics/stat.c, we unconditionally issue calls to stat(),
fstat() and lstat(). This is wrong, and these calls should be protected by
HAVE_{,F,L}STAT macros, themselves defined by autoconf.

This bug is annoying especially for lstat(), because it's non-POSIX and it's
not present on mingw; this, in turns, prevent us from creating a DLL
libgfortran (when the recent libtool patch by Steve Ellcey will be commited, it
will be the only bug still preventing this!). In the lstat() case, when lstat()
is not available and stat() is available, we should use it instead.

PS: We already have a test HAVE_WORKING_STAT that is used by the I/O system to
see if the system stat implementation fits the needs of the I/O code, but this
is unrelated.


-- 
           Summary: Calls lstat(), stat() and fstat() in libgfortran should
                    be protected by autoconf HAVE_{L,,F}STAT macros
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libfortran
        AssignedTo: fxcoudert at gcc dot gnu dot org
        ReportedBy: fxcoudert at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31335


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2007-04-13 19:56 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-03-24 11:02 [Bug libfortran/31335] New: Calls lstat(), stat() and fstat() in libgfortran should be protected by autoconf HAVE_{L,,F}STAT macros fxcoudert at gcc dot gnu dot org
2007-03-24 11:02 ` [Bug libfortran/31335] " fxcoudert at gcc dot gnu dot org
2007-03-24 15:25 ` fxcoudert at gcc dot gnu dot org
2007-03-25  9:12 ` dannysmith at users dot sourceforge dot net
2007-03-25  9:20 ` fxcoudert at gcc dot gnu dot org
2007-03-31 19:41 ` fxcoudert at gcc dot gnu dot org
2007-03-31 19:42 ` fxcoudert at gcc dot gnu dot org
2007-04-13 19:56 ` fxcoudert at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).