# HG changeset patch # User Richard M. Stallman # Date 1085264237 0 # Node ID 6433313b236bd2a171cd78ec1f3d621714c3c4e6 # Parent eba675d00657afcba507c9ea27903407f3f681a1 (Fread_file_name): Expand DIR if not absolute. diff -r eba675d00657 -r 6433313b236b src/fileio.c --- a/src/fileio.c Sat May 22 22:15:37 2004 +0000 +++ b/src/fileio.c Sat May 22 22:17:17 2004 +0000 @@ -6198,10 +6198,13 @@ if (NILP (dir)) dir = current_buffer->directory; + if (NILP (Ffile_name_absolute_p (dir))) + dir = Fexpand_file_name (dir, Qnil); if (NILP (default_filename)) - default_filename = !NILP (initial) - ? Fexpand_file_name (initial, dir) - : current_buffer->filename; + default_filename + = (!NILP (initial) + ? Fexpand_file_name (initial, dir) + : current_buffer->filename); /* If dir starts with user's homedir, change that to ~. */ homedir = (char *) egetenv ("HOME");