aboutsummaryrefslogtreecommitdiff
path: root/libbb/appletlib.c
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2023-03-17 13:20:53 +0000
committerRon Yorston <rmy@pobox.com>2023-03-17 13:20:53 +0000
commitcb50586aedc9725fb14dbb25263bba1598726037 (patch)
tree679fd1e914693d5c900243a780ab812e69a3f3ec /libbb/appletlib.c
parent87e7e7b1e61caa87112e3cf6527b606086b6b688 (diff)
downloadbusybox-w32-cb50586aedc9725fb14dbb25263bba1598726037.tar.gz
busybox-w32-cb50586aedc9725fb14dbb25263bba1598726037.tar.bz2
busybox-w32-cb50586aedc9725fb14dbb25263bba1598726037.zip
win32: delay adjusting code page
Commit 93a63809f9 (win32: add support for the euro currency symbol) caused all invocations of busybox-w32 to change code page 850 to 858. This has been known to cause problems with fonts in PowerShell (GitHub issue #207). Delay changing the code page until an i/o operation is imminent. Instances of PowerShell started by the `drop` applet during ssh login thus no longer have their code page adjusted.
Diffstat (limited to 'libbb/appletlib.c')
-rw-r--r--libbb/appletlib.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/libbb/appletlib.c b/libbb/appletlib.c
index 504c1f634..dacfbdd22 100644
--- a/libbb/appletlib.c
+++ b/libbb/appletlib.c
@@ -1290,9 +1290,7 @@ int main(int argc UNUSED_PARAM, char **argv)
1290 break; 1290 break;
1291 } 1291 }
1292 } 1292 }
1293# if ENABLE_FEATURE_EURO 1293
1294 init_codepage();
1295# endif
1296 /* Ignore critical errors, such as calling GetVolumeInformation() on 1294 /* Ignore critical errors, such as calling GetVolumeInformation() on
1297 * a floppy or CDROM drive with no media. */ 1295 * a floppy or CDROM drive with no media. */
1298 SetErrorMode(SEM_FAILCRITICALERRORS); 1296 SetErrorMode(SEM_FAILCRITICALERRORS);