diff src/sysdep.c @ 116:9f59509498e1 r20-1b10

Import from CVS: tag r20-1b10
author cvs
date Mon, 13 Aug 2007 09:23:06 +0200
parents 360340f9fd5f
children 25f70ba0133c
line wrap: on
line diff
--- a/src/sysdep.c	Mon Aug 13 09:21:56 2007 +0200
+++ b/src/sysdep.c	Mon Aug 13 09:23:06 2007 +0200
@@ -588,6 +588,7 @@
   Lisp_Object dir;
   unsigned char *str = 0;
   int len;
+  struct gcpro gcpro1;
 
   saved_handlers[0].code = SIGINT;
   saved_handlers[1].code = SIGQUIT;
@@ -607,8 +608,11 @@
   dir = Fsymbol_value (Qdefault_directory);
   if (!STRINGP (dir))
     goto xyzzy;
-  
-  dir = expand_and_dir_to_file (Funhandled_file_name_directory (dir), Qnil);
+
+  GCPRO1 (dir);
+  dir = Funhandled_file_name_directory (dir);
+  dir = expand_and_dir_to_file (dir, Qnil);
+  UNGCPRO;
   str = (unsigned char *) alloca (XSTRING_LENGTH (dir) + 2);
   len = XSTRING_LENGTH (dir);
   memcpy (str, XSTRING_DATA (dir), len);