comparison src/misc2.c @ 12672:4e846c9d61a8 v8.0.1214

patch 8.0.1214: accessing freed memory when EXITFREE is set commit https://github.com/vim/vim/commit/4f1982800f0aff28df6875e718a786f6c4b11ad9 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Oct 23 21:53:30 2017 +0200 patch 8.0.1214: accessing freed memory when EXITFREE is set Problem: Accessing freed memory when EXITFREE is set and there is more than one tab and window. (Dominique Pelle) Solution: Free options later. Skip redraw when exiting.
author Christian Brabandt <cb@256bit.org>
date Mon, 23 Oct 2017 22:00:05 +0200
parents 972ea22c946f
children 351cf7c67bbe
comparison
equal deleted inserted replaced
12671:cb54d8bb3344 12672:4e846c9d61a8
1133 /* Obviously named calls. */ 1133 /* Obviously named calls. */
1134 # if defined(FEAT_AUTOCMD) 1134 # if defined(FEAT_AUTOCMD)
1135 free_all_autocmds(); 1135 free_all_autocmds();
1136 # endif 1136 # endif
1137 clear_termcodes(); 1137 clear_termcodes();
1138 free_all_options();
1139 free_all_marks(); 1138 free_all_marks();
1140 alist_clear(&global_alist); 1139 alist_clear(&global_alist);
1141 free_homedir(); 1140 free_homedir();
1142 # if defined(FEAT_CMDL_COMPL) 1141 # if defined(FEAT_CMDL_COMPL)
1143 free_users(); 1142 free_users();
1193 /* Close all script inputs. */ 1192 /* Close all script inputs. */
1194 close_all_scripts(); 1193 close_all_scripts();
1195 1194
1196 /* Destroy all windows. Must come before freeing buffers. */ 1195 /* Destroy all windows. Must come before freeing buffers. */
1197 win_free_all(); 1196 win_free_all();
1197
1198 /* Free all option values. Must come after closing windows. */
1199 free_all_options();
1198 1200
1199 /* Free all buffers. Reset 'autochdir' to avoid accessing things that 1201 /* Free all buffers. Reset 'autochdir' to avoid accessing things that
1200 * were freed already. */ 1202 * were freed already. */
1201 #ifdef FEAT_AUTOCHDIR 1203 #ifdef FEAT_AUTOCHDIR
1202 p_acd = FALSE; 1204 p_acd = FALSE;