[vlc-commits] iconv: use vlc_strerror_c()
Rémi Denis-Courmont
git at videolan.org
Sun Dec 29 15:16:30 CET 2013
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Dec 29 15:41:42 2013 +0200| [53b501a18b463089e414df1ab71807a3837d5e71] | committer: Rémi Denis-Courmont
iconv: use vlc_strerror_c()
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=53b501a18b463089e414df1ab71807a3837d5e71
---
modules/codec/subsdec.c | 4 +++-
modules/text_renderer/text_renderer.c | 4 +++-
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/modules/codec/subsdec.c b/modules/codec/subsdec.c
index a9929b5..1b4276e 100644
--- a/modules/codec/subsdec.c
+++ b/modules/codec/subsdec.c
@@ -32,6 +32,7 @@
#endif
#include <limits.h>
+#include <errno.h>
#include <vlc_common.h>
#include <vlc_plugin.h>
@@ -308,7 +309,8 @@ static int OpenDecoder( vlc_object_t *p_this )
{
p_sys->iconv_handle = vlc_iconv_open ("UTF-8", encoding);
if (p_sys->iconv_handle == (vlc_iconv_t)(-1))
- msg_Err (p_dec, "cannot convert from %s: %m", encoding);
+ msg_Err (p_dec, "cannot convert from %s: %s", encoding,
+ vlc_strerror_c(errno));
}
free (var);
diff --git a/modules/text_renderer/text_renderer.c b/modules/text_renderer/text_renderer.c
index 91857c1..d272621 100644
--- a/modules/text_renderer/text_renderer.c
+++ b/modules/text_renderer/text_renderer.c
@@ -29,6 +29,7 @@
# include "config.h"
#endif
+#include <errno.h>
#include <vlc_common.h>
#include <vlc_variables.h>
#include <vlc_filter.h> /* filter_sys_t */
@@ -468,7 +469,8 @@ unsigned SetupText( filter_t *p_filter,
}
else
{
- msg_Warn( p_filter, "failed to convert string to unicode (%m)" );
+ msg_Warn( p_filter, "failed to convert string to unicode (%s)",
+ vlc_strerror_c(errno) );
i_string_length = 0;
}
More information about the vlc-commits
mailing list