From: Jim Meyering Date: Sat, 30 Jul 1994 14:17:26 +0000 (+0000) Subject: . X-Git-Tag: textutils-1_12_1~641 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2399435ba4e29bd1fb10efc382532ad45d00a1f7;p=thirdparty%2Fcoreutils.git . --- diff --git a/src/chmod.c b/src/chmod.c index 641f1ecbd9..c2d1c879af 100644 --- a/src/chmod.c +++ b/src/chmod.c @@ -40,8 +40,8 @@ #include "modechange.h" #include "system.h" #include "version.h" - -int lstat (); +#include "safe-stat.h" +#include "safe-lstat.h" char *savedir (); char *xmalloc (); @@ -196,7 +196,7 @@ change_file_mode (file, changes, deref_symlink) unsigned short newmode; int errors = 0; - if (lstat (file, &file_stats)) + if (SAFE_LSTAT (file, &file_stats)) { if (force_silent == 0) error (0, errno, "%s", file); @@ -207,7 +207,7 @@ change_file_mode (file, changes, deref_symlink) if (! deref_symlink) return 0; else - if (stat (file, &file_stats)) + if (SAFE_STAT (file, &file_stats)) { if (force_silent == 0) error (0, errno, "%s", file);