From 75ee544f99ca66be8105570c6309d95435ad30d1 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Thu, 6 Jun 2019 18:05:25 +0200 Subject: patch 8.1.1484: some tests are slow Problem: Some tests are slow. Solution: Add timing to the test messages. Fix double free when quitting in VimLeavePre autocmd. --- src/eval.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/eval.c') diff --git a/src/eval.c b/src/eval.c index af7a4af8a..5452f4543 100644 --- a/src/eval.c +++ b/src/eval.c @@ -430,11 +430,12 @@ eval_clear(void) vim_free(SCRIPT_SV(i)); ga_clear(&ga_scripts); - /* unreferenced lists and dicts */ - (void)garbage_collect(FALSE); - - /* functions */ + // functions need to be freed before gargabe collecting, otherwise local + // variables might be freed twice. free_all_functions(); + + // unreferenced lists and dicts + (void)garbage_collect(FALSE); } #endif -- cgit v1.2.1