]> granicus.if.org Git - vim/commitdiff
patch 8.0.0294: argument list is not stored correctly in a session file v8.0.0294
authorBram Moolenaar <Bram@vim.org>
Wed, 1 Feb 2017 21:52:44 +0000 (22:52 +0100)
committerBram Moolenaar <Bram@vim.org>
Wed, 1 Feb 2017 21:52:44 +0000 (22:52 +0100)
Problem:    Argument list is not stored correctly in a session file.
            (lgpasquale)
Solution:   Use "$argadd" instead of "argadd". (closes #1434)

src/ex_docmd.c
src/testdir/test_mksession.vim
src/version.c

index 1a10bb05776e6a33d052ded879f5674b8f1eb650..f93c7665134c919b855030c372b2e4f4f7c414f5 100644 (file)
@@ -11790,7 +11790,7 @@ ses_arglist(
                    s = buf;
                }
            }
-           if (fputs("argadd ", fd) < 0
+           if (fputs("$argadd ", fd) < 0
                    || ses_put_fname(fd, s, flagp) == FAIL
                    || put_eol(fd) == FAIL)
            {
index a51180cf0bdef5fd2a677ac20c1015a66ee56134..6ea3255dff3657e3c77859fb389f68dafef9b71a 100644 (file)
@@ -110,4 +110,16 @@ func Test_mksession_winheight()
   call delete('Xtest_mks.out')
 endfunc
 
+func Test_mksession_arglist()
+  argdel *
+  next file1 file2 file3 file4
+  mksession! Xtest_mks.out
+  source Xtest_mks.out
+  call assert_equal(['file1', 'file2', 'file3', 'file4'], argv())
+
+  call delete('Xtest_mks.out')
+  argdel *
+endfunc
+
+
 " vim: shiftwidth=2 sts=2 expandtab
index 0a5e3d3298304835304f8f9948da5ae1def09433..4a796bfc2629197a2cec25b23553a290613aea61 100644 (file)
@@ -764,6 +764,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    294,
 /**/
     293,
 /**/