changeset 2650:f378d89945e1

* fileio.c (Fmake_symbolic_link): If a file already exists under the link's filename, delete the file which the link would replace, not the file the link would point at.
author Jim Blandy <jimb@redhat.com>
date Tue, 04 May 1993 02:29:57 +0000
parents 3a9fb5d6d259
children d3f05a05fe2a
files src/fileio.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/fileio.c	Tue May 04 02:29:06 1993 +0000
+++ b/src/fileio.c	Tue May 04 02:29:57 1993 +0000
@@ -1864,7 +1864,7 @@
       /* If we didn't complain already, silently delete existing file.  */
       if (errno == EEXIST)
 	{
-	  unlink (XSTRING (filename)->data);
+	  unlink (XSTRING (linkname)->data);
 	  if (0 <= symlink (XSTRING (filename)->data, XSTRING (linkname)->data))
 	    return Qnil;
 	}