]> git.eshelyaron.com Git - emacs.git/commitdiff
(Fx_file_dialog): Encode strings in system coding system before
authorJason Rumney <jasonr@gnu.org>
Thu, 15 Jul 2004 19:57:05 +0000 (19:57 +0000)
committerJason Rumney <jasonr@gnu.org>
Thu, 15 Jul 2004 19:57:05 +0000 (19:57 +0000)
passing them to OS functions for display.

src/w32fns.c

index b12bd7be28ba6152aceb701163e25cd7ce8e83f7..d5ba6e9b0789df4158c2db9851c0e796aedcd762 100644 (file)
@@ -7735,14 +7735,14 @@ specified.  Ensure that file exists if MUSTMATCH is non-nil.  */)
   /* Create the dialog with PROMPT as title, using DIR as initial
      directory and using "*" as pattern.  */
   dir = Fexpand_file_name (dir, Qnil);
-  strncpy (init_dir, SDATA (dir), MAX_PATH);
+  strncpy (init_dir, SDATA (ENCODE_SYSTEM (dir)), MAX_PATH);
   init_dir[MAX_PATH] = '\0';
   unixtodos_filename (init_dir);
 
   if (STRINGP (default_filename))
     {
       char *file_name_only;
-      char *full_path_name = SDATA (default_filename);
+      char *full_path_name = SDATA (ENCODE_SYSTEM (default_filename));
 
       unixtodos_filename (full_path_name);