diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2012-07-10 23:09:09 -0700 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2012-07-10 23:09:09 -0700 |
commit | 57054ddd444bd1702f2bcc08321d3ed3a644448e (patch) | |
tree | 0d4c61ece563b3fd27b39e4fc062092d83398cca /src | |
parent | b747d3f7535fe324b0ea21d53c4f84970335022a (diff) | |
download | emacs-57054ddd444bd1702f2bcc08321d3ed3a644448e.tar.gz |
Assume rename.
Diffstat (limited to 'src')
-rw-r--r-- | src/ChangeLog | 3 | ||||
-rw-r--r-- | src/sysdep.c | 23 |
2 files changed, 3 insertions, 23 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 749bc12328c..7b47636969e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,8 @@ 2012-07-11 Paul Eggert <eggert@cs.ucla.edu> + Assume rename. + * sysdep.c (rename) [!HAVE_RENAME]: Remove. + Assume perror. * s/hpux10-20.h (HAVE_PERROR): Remove. * sysdep.c (perror) [HPUX && !HAVE_PERROR]: diff --git a/src/sysdep.c b/src/sysdep.c index 4bbe939dd74..274e000e9f3 100644 --- a/src/sysdep.c +++ b/src/sysdep.c @@ -2001,29 +2001,6 @@ getwd (char *pathname) #endif /* HAVE_GETWD */ /* - * Emulate rename using unlink/link. Note that this is - * only partially correct. Also, doesn't enforce restriction - * that files be of same type (regular->regular, dir->dir, etc). - */ - -#ifndef HAVE_RENAME - -int -rename (const char *from, const char *to) -{ - if (access (from, 0) == 0) - { - unlink (to); - if (link (from, to) == 0) - if (unlink (from) == 0) - return (0); - } - return (-1); -} - -#endif - -/* * This function will go away as soon as all the stubs fixed. (fnf) */ |