home *** CD-ROM | disk | FTP | other *** search
/ vim.ftp.fu-berlin.de / 2015-02-03.vim.ftp.fu-berlin.de.tar / vim.ftp.fu-berlin.de / patches / 6.2.478 < prev    next >
Encoding:
Internet Message Format  |  2004-04-15  |  3.7 KB

  1. To: vim-dev@vim.org
  2. Subject: Patch 6.2.478
  3. Fcc: outbox
  4. From: Bram Moolenaar <Bram@moolenaar.net>
  5. Mime-Version: 1.0
  6. Content-Type: text/plain; charset=ISO-8859-1
  7. Content-Transfer-Encoding: 8bit
  8. ------------
  9.  
  10. Patch 6.2.478
  11. Problem:    Win32: "--remote file" fails changing directory if the current
  12.         directory name starts with a single quote.  (Iestyn Walters)
  13. Solution:   Add a backslash where it will be removed later.
  14. Files:        src/main.c, src/misc2.c, src/proto/misc2.pro
  15.  
  16.  
  17. *** ../vim-6.2.477/src/main.c    Fri Apr 16 20:18:29 2004
  18. --- src/main.c    Fri Apr 16 20:45:43 2004
  19. ***************
  20. *** 3033,3039 ****
  21.       mainerr_arg_missing((char_u *)filev[-1]);
  22.       if (mch_dirname(cwd, MAXPATHL) != OK)
  23.       return NULL;
  24. !     if ((p = vim_strsave_escaped(cwd, PATH_ESC_CHARS)) == NULL)
  25.       return NULL;
  26.       ga_init2(&ga, 1, 100);
  27.       ga_concat(&ga, (char_u *)"<C-\\><C-N>:cd ");
  28. --- 3033,3039 ----
  29.       mainerr_arg_missing((char_u *)filev[-1]);
  30.       if (mch_dirname(cwd, MAXPATHL) != OK)
  31.       return NULL;
  32. !     if ((p = vim_strsave_escaped_ext(cwd, PATH_ESC_CHARS, TRUE)) == NULL)
  33.       return NULL;
  34.       ga_init2(&ga, 1, 100);
  35.       ga_concat(&ga, (char_u *)"<C-\\><C-N>:cd ");
  36. *** ../vim-6.2.477/src/misc2.c    Fri Apr 16 11:14:51 2004
  37. --- src/misc2.c    Fri Apr 16 21:07:36 2004
  38. ***************
  39. *** 979,984 ****
  40. --- 979,997 ----
  41.       char_u    *string;
  42.       char_u    *esc_chars;
  43.   {
  44. +     return vim_strsave_escaped_ext(string, esc_chars, FALSE);
  45. + }
  46. + /*
  47. +  * Same as vim_strsave_escaped(), but when "bsl" is TRUE also escape
  48. +  * characters where rem_backslash() would remove the backslash.
  49. +  */
  50. +     char_u *
  51. + vim_strsave_escaped_ext(string, esc_chars, bsl)
  52. +     char_u    *string;
  53. +     char_u    *esc_chars;
  54. +     int        bsl;
  55. + {
  56.       char_u    *p;
  57.       char_u    *p2;
  58.       char_u    *escaped_string;
  59. ***************
  60. *** 1002,1008 ****
  61.           continue;
  62.       }
  63.   #endif
  64. !     if (vim_strchr(esc_chars, *p) != NULL)
  65.           ++length;            /* count a backslash */
  66.       ++length;            /* count an ordinary char */
  67.       }
  68. --- 1015,1021 ----
  69.           continue;
  70.       }
  71.   #endif
  72. !     if (vim_strchr(esc_chars, *p) != NULL || (bsl && rem_backslash(p)))
  73.           ++length;            /* count a backslash */
  74.       ++length;            /* count an ordinary char */
  75.       }
  76. ***************
  77. *** 1021,1027 ****
  78.           continue;
  79.           }
  80.   #endif
  81. !         if (vim_strchr(esc_chars, *p) != NULL)
  82.           *p2++ = '\\';
  83.           *p2++ = *p;
  84.       }
  85. --- 1034,1040 ----
  86.           continue;
  87.           }
  88.   #endif
  89. !         if (vim_strchr(esc_chars, *p) != NULL || (bsl && rem_backslash(p)))
  90.           *p2++ = '\\';
  91.           *p2++ = *p;
  92.       }
  93. *** ../vim-6.2.477/src/proto/misc2.pro    Sun Jun  1 12:26:15 2003
  94. --- src/proto/misc2.pro    Fri Apr 16 20:52:44 2004
  95. ***************
  96. *** 27,32 ****
  97. --- 27,33 ----
  98.   char_u *vim_strsave __ARGS((char_u *string));
  99.   char_u *vim_strnsave __ARGS((char_u *string, int len));
  100.   char_u *vim_strsave_escaped __ARGS((char_u *string, char_u *esc_chars));
  101. + char_u *vim_strsave_escaped_ext __ARGS((char_u *string, char_u *esc_chars, int bsl));
  102.   char_u *vim_strsave_up __ARGS((char_u *string));
  103.   char_u *vim_strnsave_up __ARGS((char_u *string, int len));
  104.   void vim_strup __ARGS((char_u *p));
  105. *** ../vim-6.2.477/src/version.c    Fri Apr 16 20:18:29 2004
  106. --- src/version.c    Fri Apr 16 21:09:10 2004
  107. ***************
  108. *** 639,640 ****
  109. --- 639,642 ----
  110.   {   /* Add new patch number below this line */
  111. + /**/
  112. +     478,
  113.   /**/
  114.  
  115. -- 
  116. Yesterday, all my deadlines seemed so far away
  117. now it looks as though it's freeze in four days
  118. oh I believe in cvs..
  119.     [ CVS log "Beatles style" for FreeBSD ports/INDEX, Satoshi Asami ]
  120.  
  121.  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
  122. ///        Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
  123. \\\              Project leader for A-A-P -- http://www.A-A-P.org        ///
  124.  \\\  Buy at Amazon and help AIDS victims -- http://ICCF.nl/click1.html ///
  125.