소스 검색

Merge pull request #7622 from richardkchapman/unicode-thread-core

HPCC-13941 Make unicode conversions thread safe.

Reviewed-By: Attila Vamos <attila.vamos@lexisnexis.com>
Reviewed-By: Richard Chapman <rchapman@hpccsystems.com>
Richard Chapman 10 년 전
부모
커밋
971838a1d4
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      rtl/eclrtl/eclrtl.cpp

+ 4 - 0
rtl/eclrtl/eclrtl.cpp

@@ -314,8 +314,12 @@ CriticalSection ucmCrit;
 static void clearUnicodeConverterMap()
 {
     delete unicodeConverterMap;
+    unicodeConverterMap = NULL;  // Important to clear, as this is called when threadpool threads end...
     if (prevThreadTerminator)
+    {
         (*prevThreadTerminator)();
+        prevThreadTerminator = NULL;
+    }
 }
 
 RTLUnicodeConverter * queryRTLUnicodeConverter(char const * codepage)