Mercurial > hg > octave-nkf
diff liboctave/file-stat.cc @ 3141:292ff0bf484b
[project @ 1998-02-03 08:11:07 by jwe]
author | jwe |
---|---|
date | Tue, 03 Feb 1998 08:11:22 +0000 |
parents | 66ef74ee5d9f |
children | cd454a6fa1a4 |
line wrap: on
line diff
--- a/liboctave/file-stat.cc +++ b/liboctave/file-stat.cc @@ -37,10 +37,13 @@ #include "file-stat.h" #include "statdefs.h" -// These must come after <sys/types.h> and <sys/stat.h>. - -#include <safe-lstat.h> -#include <safe-stat.h> +#if !defined (HAVE_LSTAT) +static inline int +lstat (const char *name, struct stat *buf) +{ + return stat (name, buf); +} +#endif // XXX FIXME XXX -- the is_* and mode_as_string functions are only valid // for initialized objects. If called for an object that is not @@ -155,8 +158,7 @@ struct stat buf; - int status = follow_links - ? SAFE_STAT (cname, &buf) : SAFE_LSTAT (cname, &buf); + int status = follow_links ? stat (cname, &buf) : lstat (cname, &buf); if (status < 0) {