aboutsummaryrefslogtreecommitdiff
path: root/libltrace.c
diff options
context:
space:
mode:
authorPetr Machata <pmachata@redhat.com>2013-11-11 02:24:42 +0100
committerPetr Machata <pmachata@redhat.com>2013-11-11 02:24:42 +0100
commitc00837c2928da53a3515b107399b742ea157e78a (patch)
tree8d68002e600f53c912433310ced3b13fb2883b95 /libltrace.c
parent0ffc085b0e5ee3474ac2251f16be4f206970ebfe (diff)
downloadltrace-c00837c2928da53a3515b107399b742ea157e78a.tar.gz
Support wide character strings
- "string" lens and "format" pack were extended such that using an integer as underlying array type denotes a wide character string. - several prototypes from wchar.h were added to libc.so.conf. - ltrace.conf.5 was updated
Diffstat (limited to 'libltrace.c')
-rw-r--r--libltrace.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/libltrace.c b/libltrace.c
index d43a9b2..a8dd61e 100644
--- a/libltrace.c
+++ b/libltrace.c
@@ -21,10 +21,11 @@
#include "config.h"
-#include <limits.h>
#include <sys/param.h>
#include <sys/wait.h>
#include <errno.h>
+#include <limits.h>
+#include <locale.h>
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
@@ -99,7 +100,10 @@ normal_exit(void)
}
void
-ltrace_init(int argc, char **argv) {
+ltrace_init(int argc, char **argv)
+{
+ setlocale(LC_ALL, "");
+
struct opt_p_t *opt_p_tmp;
atexit(normal_exit);