diff options
| author | Richard M. Stallman <rms@gnu.org> | 1994-09-25 00:40:46 +0000 |
|---|---|---|
| committer | Richard M. Stallman <rms@gnu.org> | 1994-09-25 00:40:46 +0000 |
| commit | 8334eb211b99a15d491404bfca1cff991a7494ed (patch) | |
| tree | 82831000a8a8d19b4cea761f1731b8789f4fcf30 /src | |
| parent | 6b4b91a4c1d88b47a856ba3f7404024895562145 (diff) | |
| download | emacs-8334eb211b99a15d491404bfca1cff991a7494ed.tar.gz | |
(set_file_times): Don't test HAVE_UTIME.
Assume utime exists if utimes does not.
Diffstat (limited to 'src')
| -rw-r--r-- | src/sysdep.c | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/src/sysdep.c b/src/sysdep.c index fe31b599830..cace5fa4ac1 100644 --- a/src/sysdep.c +++ b/src/sysdep.c @@ -3355,16 +3355,15 @@ readdirver (dirp) int set_file_times (path, atime, mtime) - char *path; + char *filename; EMACS_TIME atime, mtime; { #ifdef HAVE_UTIMES struct timeval tv[2]; tv[0] = atime; tv[1] = mtime; - return utimes (path, tv); -#else -#ifdef HAVE_UTIME + return utimes (filename, tv); +#else /* not HAVE_UTIMES */ #ifndef HAVE_STRUCT_UTIMBUF struct utimbuf { long actime; @@ -3374,12 +3373,8 @@ set_file_times (path, atime, mtime) struct utimbuf utb; utb.actime = EMACS_SECS (atime); utb.modtime = EMACS_SECS (mtime); - return utime (path, &utb); -#else /* !HAVE_UTIMES && !HAVE_UTIME */ - /* Should we set errno here? If so, set it to what? */ - return -1; -#endif -#endif + return utime (filename, &utb); +#endif /* not HAVE_UTIMES */ } /* mkdir and rmdir functions, for systems which don't have them. */ |
