From 668d19980931e86058b46a58d0328c3b881b8aa1 Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Mon, 18 May 2020 14:40:04 -0600 Subject: Make PL_utf8_foldclosures interpreter level This resolves #17774. This ticket is because the fixes in GH #17154 failed to get every case, leaving this one outlier to be fixed by this commit. The text in https://github.com/Perl/perl5/issues/17154 gives extensive details as to the problem. But briefly, in an attempt to speed up interpreter cloning, I moved certain SVs from interpreter level to global level in e80a0113c4a8036dfb22aec44d0a9feb65d36fed (v5.27.11, March 2018). This was doable, we thought, because the content of these SVs is constant throughout the life of the program, so no need to copy them when cloning a new interpreter or thread. However when an interpreter exits, all its SVs get cleaned up, which caused these to become garbage in applications where another interpreter remains running. This circumstance is rare enough that the bug wasn't reported until September 2019, #17154. I made an initial attempt to fix the problem, and closed that ticket, but I overlooked one of the variables, which was reported in #17774, which this commit addresses. Effectively the behavior is reverted to the way it was before e80a0113c4a8036dfb22aec44d0a9feb65d36fed. --- perlapi.h | 2 -- 1 file changed, 2 deletions(-) (limited to 'perlapi.h') diff --git a/perlapi.h b/perlapi.h index f3ef930c06..305c11d413 100644 --- a/perlapi.h +++ b/perlapi.h @@ -215,8 +215,6 @@ END_EXTERN_C #define PL_user_def_props_aTHX (*Perl_Guser_def_props_aTHX_ptr(NULL)) #undef PL_user_prop_mutex #define PL_user_prop_mutex (*Perl_Guser_prop_mutex_ptr(NULL)) -#undef PL_utf8_foldclosures -#define PL_utf8_foldclosures (*Perl_Gutf8_foldclosures_ptr(NULL)) #undef PL_veto_cleanup #define PL_veto_cleanup (*Perl_Gveto_cleanup_ptr(NULL)) #undef PL_watch_pvx -- cgit v1.2.1