summaryrefslogtreecommitdiff
path: root/data/vim/patches/8.1.0868
blob: 0e10b89bfd40f284db056b6c3bb1ebc4f7fafdd8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
To: vim_dev@googlegroups.com
Subject: Patch 8.1.0868
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------

Patch 8.1.0868
Problem:    Crash if triggering garbage collector after a function call.
            (Michael Henry)
Solution:   Don't call the garbage collector right away, do it later.
            (closes #3894)
Files:	    src/userfunc.c


*** ../vim-8.1.0867/src/userfunc.c	2019-01-26 17:28:22.236599060 +0100
--- src/userfunc.c	2019-02-02 13:54:42.694976789 +0100
***************
*** 679,688 ****
  	{
  	    // We have made a lot of copies.  This can happen when
  	    // repetitively calling a function that creates a reference to
! 	    // itself somehow.  Call the garbage collector here to avoid using
  	    // too much memory.
  	    made_copy = 0;
! 	    (void)garbage_collect(FALSE);
  	}
      }
  }
--- 679,688 ----
  	{
  	    // We have made a lot of copies.  This can happen when
  	    // repetitively calling a function that creates a reference to
! 	    // itself somehow.  Call the garbage collector soon to avoid using
  	    // too much memory.
  	    made_copy = 0;
! 	    want_garbage_collect = TRUE;
  	}
      }
  }
*** ../vim-8.1.0867/src/version.c	2019-02-01 22:10:13.000410600 +0100
--- src/version.c	2019-02-02 13:56:09.066466588 +0100
***************
*** 785,786 ****
--- 785,788 ----
  {   /* Add new patch number below this line */
+ /**/
+     868,
  /**/

-- 
Save the plankton - eat a whale.

 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///