]> git.eshelyaron.com Git - emacs.git/commitdiff
(expand_and_dir_to_file): Use Fdirectory_file_name.
authorRichard M. Stallman <rms@gnu.org>
Sun, 8 Aug 1993 05:17:22 +0000 (05:17 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sun, 8 Aug 1993 05:17:22 +0000 (05:17 +0000)
src/fileio.c

index 6a94b2c34dabf61b69e46470aeb025f79331d845..b9a7dc478bb3ae5282d09d17a81cd1952394825f 100644 (file)
@@ -1526,8 +1526,8 @@ expand_and_dir_to_file (filename, defdir)
      stat behaves differently depending!  */
   if (XSTRING (abspath)->size > 1
       && XSTRING (abspath)->data[XSTRING (abspath)->size - 1] == '/')
-    abspath = Fsubstring (abspath, make_number (0),
-                         make_number (XSTRING (abspath)->size - 1));
+    /* We cannot take shortcuts; they might be wrong for magic file names.  */
+    abspath = Fdirectory_file_name (abspath);
 #endif
   return abspath;
 }