To: [email protected]
Subject: Patch 6.3a.024
Fcc: outbox
From: Bram Moolenaar <[email protected]>
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
------------

Patch 6.3a.024
Problem:    The "save all" toolbar item fails for buffers that don't have a
           name.  When using ":wa" or closing the Vim window and there are
           nameless buffers, browsing for a name may cause the name being
           given to the wrong buffer or not stored properly.  ":browse" only
           worked for one file.
Solution:   Use ":confirm browse" for "save all".
           Pass buffer argument to setfname().  Restore "browse" flag and
           "forceit" after doing the work for one file.
Files:      runtime/menu.vim, src/buffer.c, src/ex_cmds.c, src/ex_cmds2.c,
           src/ex_docmd.c, src/ex_getln.c, src/fileio.c, src/memline.c,
           src/message.c, src/window.c, src/proto/buffer.pro,
           src/proto/ex_cmds2.pro, src/proto/memline.pro


*** ../vim-6.3a.023/runtime/menu.vim    Wed May 12 17:33:08 2004
--- runtime/menu.vim    Fri May 14 12:00:52 2004
***************
*** 2,8 ****
 " You can also use this as a start for your own set of menus.
 "
 " Maintainer: Bram Moolenaar <[email protected]>
! " Last Change:        2004 May 09

 " Note that ":an" (short for ":anoremenu") is often used to make a menu work
 " in all modes and avoid side effects from mappings defined by the user.
--- 2,8 ----
 " You can also use this as a start for your own set of menus.
 "
 " Maintainer: Bram Moolenaar <[email protected]>
! " Last Change:        2004 May 14

 " Note that ":an" (short for ":anoremenu") is often used to make a menu work
 " in all modes and avoid side effects from mappings defined by the user.
***************
*** 796,802 ****
 if has("toolbar")
   an 1.10 ToolBar.Open                        :browse confirm e<CR>
   an <silent> 1.20 ToolBar.Save               :if expand("%") == ""<Bar>browse confirm w<Bar>else<Bar>confirm w<Bar>endif<CR>
!   an 1.30 ToolBar.SaveAll             :wa<CR>

   if has("printer")
     an 1.40   ToolBar.Print           :hardcopy<CR>
--- 796,802 ----
 if has("toolbar")
   an 1.10 ToolBar.Open                        :browse confirm e<CR>
   an <silent> 1.20 ToolBar.Save               :if expand("%") == ""<Bar>browse confirm w<Bar>else<Bar>confirm w<Bar>endif<CR>
!   an 1.30 ToolBar.SaveAll             :browse confirm wa<CR>

   if has("printer")
     an 1.40   ToolBar.Print           :hardcopy<CR>
*** ../vim-6.3a.023/src/buffer.c        Fri May  7 10:59:39 2004
--- src/buffer.c        Fri May 14 14:51:31 2004
***************
*** 1393,1399 ****
     struct stat       st;
 #endif

!     fname_expand(&ffname, &sfname);   /* will allocate ffname */

     /*
      * If file name already exists in the list, update the entry.
--- 1393,1399 ----
     struct stat       st;
 #endif

!     fname_expand(curbuf, &ffname, &sfname);   /* will allocate ffname */

     /*
      * If file name already exists in the list, update the entry.
***************
*** 1796,1803 ****
 }

 /*
!  * find file in buffer list by name (it has to be for the current window)
!  * 'ffname' must have a full path.
  */
     buf_T *
 buflist_findname(ffname)
--- 1796,1803 ----
 }

 /*
!  * Find file in buffer list by name (it has to be for the current window).
!  * "ffname" must have a full path.
  */
     buf_T *
 buflist_findname(ffname)
***************
*** 2369,2402 ****
 }

 /*
!  * Set the current file name to 'ffname', short file name to 'sfname'.
  * The file name with the full path is also remembered, for when :cd is used.
  * Returns FAIL for failure (file name already in use by other buffer)
  *    OK otherwise.
  */
     int
! setfname(ffname, sfname, message)
!     char_u *ffname, *sfname;
!     int           message;
! {
     buf_T     *buf;
 #ifdef UNIX
     struct stat st;
 #endif

     if (ffname == NULL || *ffname == NUL)
     {
!       vim_free(curbuf->b_ffname);
!       vim_free(curbuf->b_sfname);
!       curbuf->b_ffname = NULL;
!       curbuf->b_sfname = NULL;
 #ifdef UNIX
       st.st_dev = (dev_T)-1;
 #endif
     }
     else
     {
!       fname_expand(&ffname, &sfname);     /* will allocate ffname */
       if (ffname == NULL)                 /* out of memory */
           return FAIL;

--- 2369,2404 ----
 }

 /*
!  * Set the file name for "buf"' to 'ffname', short file name to 'sfname'.
  * The file name with the full path is also remembered, for when :cd is used.
  * Returns FAIL for failure (file name already in use by other buffer)
  *    OK otherwise.
  */
     int
! setfname(buf, ffname, sfname, message)
     buf_T     *buf;
+     char_u    *ffname, *sfname;
+     int               message;
+ {
+     buf_T     *obuf;
 #ifdef UNIX
     struct stat st;
 #endif

     if (ffname == NULL || *ffname == NUL)
     {
!       /* Removing the name. */
!       vim_free(buf->b_ffname);
!       vim_free(buf->b_sfname);
!       buf->b_ffname = NULL;
!       buf->b_sfname = NULL;
 #ifdef UNIX
       st.st_dev = (dev_T)-1;
 #endif
     }
     else
     {
!       fname_expand(buf, &ffname, &sfname); /* will allocate ffname */
       if (ffname == NULL)                 /* out of memory */
           return FAIL;

***************
*** 2408,2427 ****
 #ifdef UNIX
       if (mch_stat((char *)ffname, &st) < 0)
           st.st_dev = (dev_T)-1;
!       buf = buflist_findname_stat(ffname, &st);
 #else
!       buf = buflist_findname(ffname);
 #endif
!       if (buf != NULL && buf != curbuf)
       {
!           if (buf->b_ml.ml_mfp != NULL)       /* it's loaded, fail */
           {
               if (message)
                   EMSG(_("E95: Buffer with this name already exists"));
               vim_free(ffname);
               return FAIL;
           }
!           close_buffer(NULL, buf, DOBUF_WIPE); /* delete from the list */
       }
       sfname = vim_strsave(sfname);
       if (ffname == NULL || sfname == NULL)
--- 2410,2429 ----
 #ifdef UNIX
       if (mch_stat((char *)ffname, &st) < 0)
           st.st_dev = (dev_T)-1;
!       obuf = buflist_findname_stat(ffname, &st);
 #else
!       obuf = buflist_findname(ffname);
 #endif
!       if (obuf != NULL && obuf != buf)
       {
!           if (obuf->b_ml.ml_mfp != NULL)      /* it's loaded, fail */
           {
               if (message)
                   EMSG(_("E95: Buffer with this name already exists"));
               vim_free(ffname);
               return FAIL;
           }
!           close_buffer(NULL, obuf, DOBUF_WIPE); /* delete from the list */
       }
       sfname = vim_strsave(sfname);
       if (ffname == NULL || sfname == NULL)
***************
*** 2436,2487 ****
 # endif
           fname_case(sfname, 0);    /* set correct case for short file name */
 #endif
!       vim_free(curbuf->b_ffname);
!       vim_free(curbuf->b_sfname);
!       curbuf->b_ffname = ffname;
!       curbuf->b_sfname = sfname;
     }
!     curbuf->b_fname = curbuf->b_sfname;
 #ifdef UNIX
     if (st.st_dev == (dev_T)-1)
!       curbuf->b_dev = -1;
     else
     {
!       curbuf->b_dev = st.st_dev;
!       curbuf->b_ino = st.st_ino;
     }
 #endif

 #ifndef SHORT_FNAME
!     curbuf->b_shortname = FALSE;
 #endif

!     buf_name_changed();
     return OK;
 }

 /*
!  * Take care of what needs to be done when the name of the current buffer has
  * changed.
  */
     void
! buf_name_changed()
 {
     /*
      * If the file name changed, also change the name of the swapfile
      */
!     if (curbuf->b_ml.ml_mfp != NULL)
!       ml_setname();

!     check_arg_idx(curwin);    /* check file name for arg list */
 #ifdef FEAT_TITLE
     maketitle();              /* set window title */
 #endif
 #ifdef FEAT_WINDOWS
     status_redraw_all();      /* status lines need to be redrawn */
 #endif
!     fmarks_check_names(curbuf);       /* check named file marks */
!     ml_timestamp(curbuf);     /* reset timestamp */
 }

 /*
--- 2438,2491 ----
 # endif
           fname_case(sfname, 0);    /* set correct case for short file name */
 #endif
!       vim_free(buf->b_ffname);
!       vim_free(buf->b_sfname);
!       buf->b_ffname = ffname;
!       buf->b_sfname = sfname;
     }
!     buf->b_fname = buf->b_sfname;
 #ifdef UNIX
     if (st.st_dev == (dev_T)-1)
!       buf->b_dev = -1;
     else
     {
!       buf->b_dev = st.st_dev;
!       buf->b_ino = st.st_ino;
     }
 #endif

 #ifndef SHORT_FNAME
!     buf->b_shortname = FALSE;
 #endif

!     buf_name_changed(buf);
     return OK;
 }

 /*
!  * Take care of what needs to be done when the name of buffer "buf" has
  * changed.
  */
     void
! buf_name_changed(buf)
!     buf_T     *buf;
 {
     /*
      * If the file name changed, also change the name of the swapfile
      */
!     if (buf->b_ml.ml_mfp != NULL)
!       ml_setname(buf);

!     if (curwin->w_buffer == buf)
!       check_arg_idx(curwin);  /* check file name for arg list */
 #ifdef FEAT_TITLE
     maketitle();              /* set window title */
 #endif
 #ifdef FEAT_WINDOWS
     status_redraw_all();      /* status lines need to be redrawn */
 #endif
!     fmarks_check_names(buf);  /* check named file marks */
!     ml_timestamp(buf);                /* reset timestamp */
 }

 /*
***************
*** 3855,3865 ****
 }

 /*
!  * make ffname a full file name, set sfname to ffname if not NULL
!  * ffname becomes a pointer to allocated memory (or NULL).
  */
     void
! fname_expand(ffname, sfname)
     char_u    **ffname;
     char_u    **sfname;
 {
--- 3859,3871 ----
 }

 /*
!  * Make "ffname" a full file name, set "sfname" to "ffname" if not NULL.
!  * "ffname" becomes a pointer to allocated memory (or NULL).
  */
+ /*ARGSUSED*/
     void
! fname_expand(buf, ffname, sfname)
!     buf_T     *buf;
     char_u    **ffname;
     char_u    **sfname;
 {
***************
*** 3870,3876 ****
     *ffname = fix_fname(*ffname);   /* expand to full path */

 #ifdef FEAT_SHORTCUT
!     if (!curbuf->b_p_bin)
     {
       char_u  *rfname = NULL;

--- 3876,3882 ----
     *ffname = fix_fname(*ffname);   /* expand to full path */

 #ifdef FEAT_SHORTCUT
!     if (!buf->b_p_bin)
     {
       char_u  *rfname = NULL;

*** ../vim-6.3a.023/src/ex_cmds.c       Fri May  7 10:59:38 2004
--- src/ex_cmds.c       Fri May 14 15:22:14 2004
***************
*** 2021,2027 ****
       xfname = curbuf->b_fname;
       curbuf->b_ffname = NULL;
       curbuf->b_sfname = NULL;
!       if (setfname(eap->arg, NULL, TRUE) == FAIL)
       {
           curbuf->b_ffname = fname;
           curbuf->b_sfname = sfname;
--- 2021,2027 ----
       xfname = curbuf->b_fname;
       curbuf->b_ffname = NULL;
       curbuf->b_sfname = NULL;
!       if (setfname(curbuf, eap->arg, NULL, TRUE) == FAIL)
       {
           curbuf->b_ffname = fname;
           curbuf->b_sfname = sfname;
***************
*** 2217,2223 ****
           fname = alt_buf->b_sfname;
           alt_buf->b_sfname = curbuf->b_sfname;
           curbuf->b_sfname = fname;
!           buf_name_changed();
 #ifdef FEAT_AUTOCMD
           apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf);
           if (!alt_buf->b_p_bl)
--- 2217,2223 ----
           fname = alt_buf->b_sfname;
           alt_buf->b_sfname = curbuf->b_sfname;
           curbuf->b_sfname = fname;
!           buf_name_changed(curbuf);
 #ifdef FEAT_AUTOCMD
           apply_autocmds(EVENT_BUFFILEPOST, NULL, NULL, FALSE, curbuf);
           if (!alt_buf->b_p_bl)
***************
*** 2336,2341 ****
--- 2336,2342 ----
 {
     buf_T     *buf;
     int               error = 0;
+     int               save_forceit = eap->forceit;

     if (eap->cmdidx == CMD_xall || eap->cmdidx == CMD_wqall)
       exiting = TRUE;
***************
*** 2359,2366 ****
 #ifdef FEAT_BROWSE
           /* ":browse wall": ask for file name if there isn't one */
           if (buf->b_ffname == NULL && cmdmod.browse)
!               buf->b_ffname = do_browse(TRUE, (char_u *)_("Save As"), NULL,
!                                                      NULL, NULL, NULL, buf);
 #endif
           if (buf->b_ffname == NULL)
           {
--- 2360,2366 ----
 #ifdef FEAT_BROWSE
           /* ":browse wall": ask for file name if there isn't one */
           if (buf->b_ffname == NULL && cmdmod.browse)
!               browse_save_fname(buf);
 #endif
           if (buf->b_ffname == NULL)
           {
***************
*** 2383,2388 ****
--- 2383,2389 ----
                   buf = firstbuf;
 #endif
           }
+           eap->forceit = save_forceit;    /* check_overwrite() may set it */
       }
     }
     if (exiting)
***************
*** 2470,2476 ****

     if (fnum == 0)
     {
!       fname_expand(&ffname, &sfname); /* make ffname full path, set sfname */
       other = otherfile(ffname);
       free_me = ffname;               /* has been allocated, free() later */
     }
--- 2471,2478 ----

     if (fnum == 0)
     {
!                                       /* make ffname full path, set sfname */
!       fname_expand(curbuf, &ffname, &sfname);
       other = otherfile(ffname);
       free_me = ffname;               /* has been allocated, free() later */
     }
*** ../vim-6.3a.023/src/ex_cmds2.c      Fri May  7 10:59:38 2004
--- src/ex_cmds2.c      Fri May 14 15:04:00 2004
***************
*** 746,758 ****

 #if defined(FEAT_GUI_DIALOG) || defined(FEAT_CON_DIALOG) || defined(PROTO)

! #ifdef FEAT_BROWSE
! static void   browse_save_fname __ARGS((buf_T *buf));
!
 /*
  * When wanting to write a file without a file name, ask the user for a name.
  */
!     static void
 browse_save_fname(buf)
     buf_T     *buf;
 {
--- 746,756 ----

 #if defined(FEAT_GUI_DIALOG) || defined(FEAT_CON_DIALOG) || defined(PROTO)

! #if defined(FEAT_BROWSE) || defined(PROTO)
 /*
  * When wanting to write a file without a file name, ask the user for a name.
  */
!     void
 browse_save_fname(buf)
     buf_T     *buf;
 {
***************
*** 764,770 ****
                                                                  NULL, buf);
       if (fname != NULL)
       {
!           setfname(fname, NULL, TRUE);
           vim_free(fname);
       }
     }
--- 762,769 ----
                                                                  NULL, buf);
       if (fname != NULL)
       {
!           if (setfname(buf, fname, NULL, TRUE) == OK)
!               buf->b_flags |= BF_NOTEDITED;
           vim_free(fname);
       }
     }
***************
*** 773,778 ****
--- 772,778 ----

 /*
  * Ask the user what to do when abondoning a changed buffer.
+  * Must check 'write' option first!
  */
     void
 dialog_changed(buf, checkall)
*** ../vim-6.3a.023/src/ex_docmd.c      Fri May  7 10:59:37 2004
--- src/ex_docmd.c      Fri May 14 14:47:33 2004
***************
*** 6306,6312 ****
     /* Set recoverymode right away to avoid the ATTENTION prompt. */
     recoverymode = TRUE;
     if (!check_changed(curbuf, p_awa, TRUE, eap->forceit, FALSE)
!               && (*eap->arg == NUL || setfname(eap->arg, NULL, TRUE) == OK))
       ml_recover();
     recoverymode = FALSE;
 }
--- 6306,6313 ----
     /* Set recoverymode right away to avoid the ATTENTION prompt. */
     recoverymode = TRUE;
     if (!check_changed(curbuf, p_awa, TRUE, eap->forceit, FALSE)
!           && (*eap->arg == NUL
!                            || setfname(curbuf, eap->arg, NULL, TRUE) == OK))
       ml_recover();
     recoverymode = FALSE;
 }
*** ../vim-6.3a.023/src/ex_getln.c      Fri May 14 16:11:37 2004
--- src/ex_getln.c      Fri May 14 14:47:41 2004
***************
*** 5151,5157 ****

     /* Create the command-line buffer empty. */
     (void)do_ecmd(0, NULL, NULL, NULL, ECMD_ONE, ECMD_HIDE);
!     (void)setfname((char_u *)"command-line", NULL, TRUE);
     set_option_value((char_u *)"bt", 0L, (char_u *)"nofile", OPT_LOCAL);
     set_option_value((char_u *)"swf", 0L, NULL, OPT_LOCAL);
     curbuf->b_p_ma = TRUE;
--- 5151,5157 ----

     /* Create the command-line buffer empty. */
     (void)do_ecmd(0, NULL, NULL, NULL, ECMD_ONE, ECMD_HIDE);
!     (void)setfname(curbuf, (char_u *)"command-line", NULL, TRUE);
     set_option_value((char_u *)"bt", 0L, (char_u *)"nofile", OPT_LOCAL);
     set_option_value((char_u *)"swf", 0L, NULL, OPT_LOCAL);
     curbuf->b_p_ma = TRUE;
*** ../vim-6.3a.023/src/fileio.c        Fri May  7 10:59:40 2004
--- src/fileio.c        Fri May 14 14:48:45 2004
***************
*** 305,311 ****
           && vim_strchr(p_cpo, CPO_FNAMER) != NULL
           && !(flags & READ_DUMMY))
     {
!       if (setfname(fname, sfname, FALSE) == OK)
           curbuf->b_flags |= BF_NOTEDITED;
     }

--- 305,311 ----
           && vim_strchr(p_cpo, CPO_FNAMER) != NULL
           && !(flags & READ_DUMMY))
     {
!       if (setfname(curbuf, fname, sfname, FALSE) == OK)
           curbuf->b_flags |= BF_NOTEDITED;
     }

***************
*** 2659,2665 ****
           return FAIL;
 #endif
 #endif
!       if (setfname(fname, sfname, FALSE) == OK)
           curbuf->b_flags |= BF_NOTEDITED;
 #ifdef FEAT_AUTOCMD
       /* ....and a new named one is created */
--- 2659,2665 ----
           return FAIL;
 #endif
 #endif
!       if (setfname(curbuf, fname, sfname, FALSE) == OK)
           curbuf->b_flags |= BF_NOTEDITED;
 #ifdef FEAT_AUTOCMD
       /* ....and a new named one is created */
*** ../vim-6.3a.023/src/memline.c       Fri May  7 10:59:38 2004
--- src/memline.c       Fri May 14 14:54:01 2004
***************
*** 354,364 ****
 }

 /*
!  * ml_setname() is called when the file name has been changed.
  * It may rename the swap file.
  */
     void
! ml_setname()
 {
     int               success = FALSE;
     memfile_T *mfp;
--- 354,365 ----
 }

 /*
!  * ml_setname() is called when the file name of "buf" has been changed.
  * It may rename the swap file.
  */
     void
! ml_setname(buf)
!     buf_T     *buf;
 {
     int               success = FALSE;
     memfile_T *mfp;
***************
*** 368,374 ****
     char_u    *p;
 #endif

!     mfp = curbuf->b_ml.ml_mfp;
     if (mfp->mf_fd < 0)                   /* there is no swap file yet */
     {
       /*
--- 369,375 ----
     char_u    *p;
 #endif

!     mfp = buf->b_ml.ml_mfp;
     if (mfp->mf_fd < 0)                   /* there is no swap file yet */
     {
       /*
***************
*** 376,382 ****
        * For help files we will make a swap file now.
        */
       if (p_uc != 0)
!           ml_open_file(curbuf);       /* create a swap file */
       return;
     }

--- 377,383 ----
        * For help files we will make a swap file now.
        */
       if (p_uc != 0)
!           ml_open_file(buf);      /* create a swap file */
       return;
     }

***************
*** 388,394 ****
     {
       if (*dirp == NUL)           /* tried all directories, fail */
           break;
!       fname = findswapname(curbuf, &dirp, mfp->mf_fname); /* alloc's fname */
       if (fname == NULL)          /* no file name found for this dir */
           continue;

--- 389,395 ----
     {
       if (*dirp == NUL)           /* tried all directories, fail */
           break;
!       fname = findswapname(buf, &dirp, mfp->mf_fname); /* alloc's fname */
       if (fname == NULL)          /* no file name found for this dir */
           continue;

***************
*** 895,901 ****
     if (directly)
     {
       expand_env(b0p->b0_fname, NameBuff, MAXPATHL);
!       if (setfname(NameBuff, NULL, TRUE) == FAIL)
           goto theend;
     }

--- 896,902 ----
     if (directly)
     {
       expand_env(b0p->b0_fname, NameBuff, MAXPATHL);
!       if (setfname(curbuf, NameBuff, NULL, TRUE) == FAIL)
           goto theend;
     }

*** ../vim-6.3a.023/src/message.c       Wed May 12 18:26:17 2004
--- src/message.c       Fri May 14 15:11:10 2004
***************
*** 3046,3054 ****
     char_u            *fname;
     static char_u     *last_dir = NULL;    /* last used directory */
     char_u            *tofree = NULL;

!
!     /* Must turn off browse straight away, or :so autocommands will get the
      * flag too!  */
     cmdmod.browse = FALSE;

--- 3046,3054 ----
     char_u            *fname;
     static char_u     *last_dir = NULL;    /* last used directory */
     char_u            *tofree = NULL;
+     int                       save_browse = cmdmod.browse;

!     /* Must turn off browse to avoid that autocommands will get the
      * flag too!  */
     cmdmod.browse = FALSE;

***************
*** 3152,3157 ****
--- 3152,3158 ----
     }

     vim_free(tofree);
+     cmdmod.browse = save_browse;

     return fname;
 }
*** ../vim-6.3a.023/src/window.c        Fri May  7 10:59:38 2004
--- src/window.c        Fri May 14 15:01:10 2004
***************
*** 2587,2602 ****
           if (!r)
           {
 #if defined(FEAT_GUI_DIALOG) || defined(FEAT_CON_DIALOG)
!               if (message && (p_confirm || cmdmod.confirm))
               {
                   dialog_changed(wp->w_buffer, FALSE);
! #ifdef FEAT_AUTOCMD
                   if (!win_valid(wp))         /* autocommands messed wp up */
                   {
                       nextwp = firstwin;
                       continue;
                   }
! #endif
               }
               if (bufIsChanged(wp->w_buffer))
 #endif
--- 2587,2602 ----
           if (!r)
           {
 #if defined(FEAT_GUI_DIALOG) || defined(FEAT_CON_DIALOG)
!               if (message && (p_confirm || cmdmod.confirm) && p_write)
               {
                   dialog_changed(wp->w_buffer, FALSE);
! # ifdef FEAT_AUTOCMD
                   if (!win_valid(wp))         /* autocommands messed wp up */
                   {
                       nextwp = firstwin;
                       continue;
                   }
! # endif
               }
               if (bufIsChanged(wp->w_buffer))
 #endif
*** ../vim-6.3a.023/src/proto/buffer.pro        Fri May  7 10:59:36 2004
--- src/proto/buffer.pro        Fri May 14 15:01:33 2004
***************
*** 24,31 ****
 linenr_T buflist_findlnum __ARGS((buf_T *buf));
 void buflist_list __ARGS((exarg_T *eap));
 int buflist_name_nr __ARGS((int fnum, char_u **fname, linenr_T *lnum));
! int setfname __ARGS((char_u *ffname, char_u *sfname, int message));
! void buf_name_changed __ARGS((void));
 buf_T *setaltfname __ARGS((char_u *ffname, char_u *sfname, linenr_T lnum));
 char_u *getaltfname __ARGS((int errmsg));
 int buflist_add __ARGS((char_u *fname, int flags));
--- 24,31 ----
 linenr_T buflist_findlnum __ARGS((buf_T *buf));
 void buflist_list __ARGS((exarg_T *eap));
 int buflist_name_nr __ARGS((int fnum, char_u **fname, linenr_T *lnum));
! int setfname __ARGS((buf_T *buf, char_u *ffname, char_u *sfname, int message));
! void buf_name_changed __ARGS((buf_T *buf));
 buf_T *setaltfname __ARGS((char_u *ffname, char_u *sfname, linenr_T lnum));
 char_u *getaltfname __ARGS((int errmsg));
 int buflist_add __ARGS((char_u *fname, int flags));
***************
*** 41,47 ****
 void get_rel_pos __ARGS((win_T *wp, char_u *str));
 int append_arg_number __ARGS((win_T *wp, char_u *buf, int add_file, int maxlen));
 char_u *fix_fname __ARGS((char_u *fname));
! void fname_expand __ARGS((char_u **ffname, char_u **sfname));
 char_u *alist_name __ARGS((aentry_T *aep));
 void do_arg_all __ARGS((int count, int forceit));
 void ex_buffer_all __ARGS((exarg_T *eap));
--- 41,47 ----
 void get_rel_pos __ARGS((win_T *wp, char_u *str));
 int append_arg_number __ARGS((win_T *wp, char_u *buf, int add_file, int maxlen));
 char_u *fix_fname __ARGS((char_u *fname));
! void fname_expand __ARGS((buf_T *buf, char_u **ffname, char_u **sfname));
 char_u *alist_name __ARGS((aentry_T *aep));
 void do_arg_all __ARGS((int count, int forceit));
 void ex_buffer_all __ARGS((exarg_T *eap));
*** ../vim-6.3a.023/src/proto/ex_cmds2.pro      Fri May  7 10:59:36 2004
--- src/proto/ex_cmds2.pro      Fri May 14 15:01:40 2004
***************
*** 12,17 ****
--- 12,18 ----
 int autowrite __ARGS((buf_T *buf, int forceit));
 void autowrite_all __ARGS((void));
 int check_changed __ARGS((buf_T *buf, int checkaw, int mult_win, int forceit, int allbuf));
+ void browse_save_fname __ARGS((buf_T *buf));
 void dialog_changed __ARGS((buf_T *buf, int checkall));
 int can_abandon __ARGS((buf_T *buf, int forceit));
 int check_changed_any __ARGS((int hidden));
*** ../vim-6.3a.023/src/proto/memline.pro       Fri May  7 10:59:36 2004
--- src/proto/memline.pro       Fri May 14 15:01:44 2004
***************
*** 1,6 ****
 /* memline.c */
 int ml_open __ARGS((void));
! void ml_setname __ARGS((void));
 void ml_open_files __ARGS((void));
 void ml_open_file __ARGS((buf_T *buf));
 void check_need_swap __ARGS((int newfile));
--- 1,6 ----
 /* memline.c */
 int ml_open __ARGS((void));
! void ml_setname __ARGS((buf_T *buf));
 void ml_open_files __ARGS((void));
 void ml_open_file __ARGS((buf_T *buf));
 void check_need_swap __ARGS((int newfile));
*** ../vim-6.3a.023/src/version.c       Fri May 14 16:11:37 2004
--- src/version.c       Fri May 14 16:15:26 2004
***************
*** 643,644 ****
--- 643,646 ----
 {   /* Add new patch number below this line */
+ /**/
+     24,
 /**/

--
Not too long ago, compress was something you did to garbage...

/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\              Project leader for A-A-P -- http://www.A-A-P.org        ///
\\\  Buy at Amazon and help AIDS victims -- http://ICCF.nl/click1.html ///