summaryrefslogtreecommitdiffstats
path: root/unix/tkUnixFont.c
diff options
context:
space:
mode:
Diffstat (limited to 'unix/tkUnixFont.c')
-rw-r--r--unix/tkUnixFont.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/unix/tkUnixFont.c b/unix/tkUnixFont.c
index dc80807..50033ec 100644
--- a/unix/tkUnixFont.c
+++ b/unix/tkUnixFont.c
@@ -316,14 +316,8 @@ TkpFontPkgInit(
Tcl_Encoding ucs2;
if (tsdPtr->controlFamily.encoding == NULL) {
- Tcl_EncodingType type;
- type.encodingName = "X11ControlChars";
- type.toUtfProc = ControlUtfProc;
- type.fromUtfProc = ControlUtfProc;
- type.freeProc = NULL;
- type.clientData = NULL;
- type.nullSize = 0;
+ Tcl_EncodingType type = {"X11ControlChars", ControlUtfProc, ControlUtfProc, NULL, NULL, 0};
tsdPtr->controlFamily.refCount = 2;
tsdPtr->controlFamily.encoding = Tcl_CreateEncoding(&type);
tsdPtr->controlFamily.isTwoByteFont = 0;
@@ -342,8 +336,8 @@ TkpFontPkgInit(
ucs2 = Tcl_GetEncoding(NULL, "ucs-2be");
if (ucs2 == NULL) {
- Tcl_EncodingType type = {"ucs-2be", Ucs2beToUtfProc, UtfToUcs2beProc, NULL, NULL, 2};
- Tcl_CreateEncoding(&type);
+ Tcl_EncodingType ucs2type = {"ucs-2be", Ucs2beToUtfProc, UtfToUcs2beProc, NULL, NULL, 2};
+ Tcl_CreateEncoding(&ucs2type);
} else {
Tcl_FreeEncoding(ucs2);
}