You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
xrdp-proprietary/common
Koichiro IWAO ceb4b7b2a4 Fix clipboard when text/filename contains non-ASCII characters
broken by #314. This is compatible with the fix introduced in #314.

To use non-ASCII text/filename in clipboard, chansrv needs to be run
with LC_CTYPE=*.UTF-8 because the behaviour of mbstowcs(3) function
called in chansrv depends on LC_CTYPE[1].  However #314 made
LC_CTYPE=C in chansrv context.  Even if LANG and LC_* are set in
.bashrc, /etc/profile, /etc/locale.conf or something like that,
it doesn't affect in chansrv context because chansrv doesn't source
any of them unlike sesman.

So do not set LC_CTYPE to blank or "C" in g_init() in order to get
g_mbstowcs and g_wcstombs to work properly with non-ASCII UTF-8
characters in any context.

Setting LC_CTYPE to *.UTF-8 doesn't obstruct applying system
language in RHEL [2].

[1] Linux man page says:
      The behavior of mbstowcs() depends on the LC_CTYPE category of
      the current locale.

[2] https://bugzilla.redhat.com/show_bug.cgi?id=1290820
10 years ago
..
Makefile.am Include stdint.h, don't redefine MAX/MIN constants if already defined 10 years ago
arch.h Declare unified module interface and use it in modules 10 years ago
crc16.h misc fixes for Xorg and compile 12 years ago
defines.h common: small fix for 32 bit color 12 years ago
fifo.c common: no logic change, remove spaces 12 years ago
fifo.h common: no logic change, remove spaces 12 years ago
file.c common: updates for file.c 10 years ago
file.h common: no logic change, update comments 12 years ago
file_loc.h Stop redefining libdir, use moduledir for ${libdir}/xrdp 10 years ago
list.c Fix more format warnings 10 years ago
list.h common: indent, not logic change 12 years ago
list16.c common: fix for list16_insert_item 12 years ago
list16.h reduce the memory needed for crc16 bitmap cache lists 12 years ago
log.c Use g_new or g_new0 when C++ compiler would complain about implicit cast 10 years ago
log.h Use enum logLevels consistently for log levels 10 years ago
os_calls.c Fix clipboard when text/filename contains non-ASCII characters 10 years ago
os_calls.h Merge pull request #390 from proski/june21 10 years ago
parse.h work on main loop changes 11 years ago
pixman-region.c Pixman fixes 10 years ago
pixman-region.h add region intersect 10 years ago
pixman-region16.c Include stdint.h, don't redefine MAX/MIN constants if already defined 10 years ago
rail.h common: no logic change, update comments 12 years ago
ssl_calls.c Use g_new or g_new0 when C++ compiler would complain about implicit cast 10 years ago
ssl_calls.h Use correct types for ssl and ctx fields in struct ssl_tls 10 years ago
thread_calls.c Add unnamed semaphore support on Mac OS 10 years ago
thread_calls.h common: no logic change, update comments 12 years ago
trans.c Use char* for TLS send and receive 10 years ago
trans.h Use char* for TLS send and receive 10 years ago
xrdp_client_info.h xrdp_wm: fix for multimon, draw login window and log window on primary 10 years ago
xrdp_constants.h Use uniform comments for GUIDs 10 years ago
xrdp_rail.h common: indent, not logic change 12 years ago