<i>CA files loaded from a VFS fail under a non-Latin-1 locale on Tcl 9 because -encoding binary is no longer valid.</i>.
by
.
D 2026-11-01T10:36:27.648
J foundin 2.0.1
J icomment Tcl\s9\sremoved\sthe\s"binary"\sencoding\salias,\sso\ssetting\sit\sfails\sand\sthe\schannel\r\nkeeps\sthe\ssystem\sencoding.\sA\sCA\sfile\swith\snon-ASCII\sbytes\sthen\scomes\sback\r\ncorrupted\sunder\sany\ssystem\sencoding\sother\sthan\siso8859-1.\sRead\sit\swith\r\n-translation\sbinary,\swhich\sTcl\s8.6\sand\s9\sboth\saccept,\sand\sstop\sif\sthat\sfails.\r\n\r\ndiff\s-ruN\sA/generic/tls.c\sB/generic/tls.c\r\n---\sA/generic/tls.c\r\n+++\sB/generic/tls.c\r\n@@\s-1908,7\s+1908,10\s@@\r\n\s\s\s\s\sif\s(in\s==\sNULL)\s{\r\n\s\tgoto\scleanup;\r\n\s\s\s\s\s}\r\n-\s\s\s\sTcl_SetChannelOption(interp,\sin,\s"-encoding",\s"binary");\r\n+\s\s\s\sif\s(Tcl_SetChannelOption(interp,\sin,\s"-translation",\s"binary")\s!=\sTCL_OK)\s{\r\n+\tTcl_Close(interp,\sin);\r\n+\tgoto\scleanup;\r\n+\s\s\s\s}\r\n\s\s\s\s\sbuf\s=\sTcl_NewObj();\r\n\s\s\s\s\sTcl_IncrRefCount(buf);
J login bandoti
J mimetype text/plain
J priority Medium
J private_contact e6a07be3001c236f35faa93e53f095fc289ddb44
J severity Important
J status Open
J title CA\sfiles\sloaded\sfrom\sa\sVFS\sfail\sunder\sa\snon-Latin-1\slocale\son\sTcl\s9\sbecause\s-encoding\sbinary\sis\sno\slonger\svalid.
J type Code\sDefect
K 869df60efcf1ed8e8856b6b43fbd29084cf989be
U bandoti
Z 9f1a1e59d33c47e83572786ff5af5f22