summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/textmode.c
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2015-12-17 16:22:49 +0100
committerCorinna Vinschen <corinna@vinschen.de>2016-01-08 15:17:52 +0100
commite0d4e3fec7793c1bf41ca707156af8413fb03455 (patch)
tree20f59f1244f1ee59db373e57e12a49077876d479 /winsup/cygwin/textmode.c
parent9ee26242405e20fb61adb2a404dd6a31f4a1f2dd (diff)
downloadcygnal-e0d4e3fec7793c1bf41ca707156af8413fb03455.tar.gz
cygnal-e0d4e3fec7793c1bf41ca707156af8413fb03455.tar.bz2
cygnal-e0d4e3fec7793c1bf41ca707156af8413fb03455.zip
Do not treat the command line or environment like paths
* dcrt0.cc (dll_crt0_1), environ.cc (environ_init, getwinenveq, build_env), strfuncs.cc (sys_wcstombs, sys_wcstombs_alloc), wchar.c (sys_wcstombs, sys_wcstombs_alloc): avoid mis-conversions of text that does not, actually, refer to a path or file name Detailed explanation: Our WCS -> UTF conversion handles the private Unicode page specially to allow for otherwise invalid file names. However, this handling makes no sense for command-lines, nor environment variables, which we would rather convert verbatim. As a stop-gap solution, let's just introduce a version of the sys_wcstombs() function that specifically excludes that file name conversion magic. The proper solution is to change sys_wcstombs() to assume that it is not a path that wants to be converted, and introduce sys_wcstombs_path() that does, but that is a bigger task which we leave for another patch. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Diffstat (limited to 'winsup/cygwin/textmode.c')
0 files changed, 0 insertions, 0 deletions