summaryrefslogtreecommitdiffstats
path: root/generic/tclEncoding.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2016-09-08 12:28:19 (GMT)
committerdgp <dgp@users.sourceforge.net>2016-09-08 12:28:19 (GMT)
commit90bd7a732609ca0664078461027a02ae6f357d97 (patch)
tree4e6118d8e9cea8226d47192cc2c42fe802864562 /generic/tclEncoding.c
parent498f733a1bd10ee1f6e8f97a3f8f4021ac9faa1f (diff)
parent71968e0f29b83374e539b31314b21a43b7ab61b6 (diff)
downloadtcl-90bd7a732609ca0664078461027a02ae6f357d97.zip
tcl-90bd7a732609ca0664078461027a02ae6f357d97.tar.gz
tcl-90bd7a732609ca0664078461027a02ae6f357d97.tar.bz2
merge 8.6.2
Diffstat (limited to 'generic/tclEncoding.c')
-rw-r--r--generic/tclEncoding.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/generic/tclEncoding.c b/generic/tclEncoding.c
index 2cc55d6..d246cb2 100644
--- a/generic/tclEncoding.c
+++ b/generic/tclEncoding.c
@@ -182,6 +182,7 @@ TCL_DECLARE_MUTEX(encodingMutex)
static Tcl_Encoding defaultEncoding;
static Tcl_Encoding systemEncoding;
+Tcl_Encoding tclIdentityEncoding;
/*
* The following variable is used in the sparse matrix code for a
@@ -567,7 +568,7 @@ TclInitEncodingSubsystem(void)
type.freeProc = NULL;
type.nullSize = 1;
type.clientData = NULL;
- Tcl_CreateEncoding(&type);
+ tclIdentityEncoding = Tcl_CreateEncoding(&type);
type.encodingName = "utf-8";
type.toUtfProc = UtfExtToUtfIntProc;
@@ -651,6 +652,7 @@ TclFinalizeEncodingSubsystem(void)
Tcl_MutexLock(&encodingMutex);
encodingsInitialized = 0;
FreeEncoding(systemEncoding);
+ FreeEncoding(tclIdentityEncoding);
hPtr = Tcl_FirstHashEntry(&encodingTable, &search);
while (hPtr != NULL) {