From 71fefd86ac7e2328ad11a8a3a49452a2e65b186b Mon Sep 17 00:00:00 2001 From: reimar Date: Sun, 31 May 2009 13:00:51 +0000 Subject: Use a malloced string for the get_term_charset return value. This is necessary at least on POSIX systems since the buffer returned by nl_langinfo may change its contents with e.g. each setlocale call. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29332 b3059339-0415-0410-9bf9-f77b7e298cf2 --- mp_msg.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'mp_msg.c') diff --git a/mp_msg.c b/mp_msg.c index e43ca17d37..85e792408d 100644 --- a/mp_msg.c +++ b/mp_msg.c @@ -8,6 +8,13 @@ #ifdef CONFIG_ICONV #include #include +/** + * \brief gets the name of the system's terminal character set + * \return a malloced string indicating the system charset + * + * Be warned that this function on many systems is in no way thread-safe + * since it modifies global data + */ char* get_term_charset(void); #endif -- cgit v1.2.3