Commit 9b89b833 authored by Rafaël Carré's avatar Rafaël Carré

lua: makes sure metadata is UTF8 encoded (some websites aren't using UTF8 charset)

parent 2e7f3ec5
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include <vlc/vlc.h> #include <vlc/vlc.h>
#include <vlc_meta.h> #include <vlc_meta.h>
#include <vlc_charset.h>
#include <lua.h> /* Low level lua C API */ #include <lua.h> /* Low level lua C API */
#include <lauxlib.h> /* Higher level C API */ #include <lauxlib.h> /* Higher level C API */
...@@ -349,6 +350,7 @@ void vlclua_read_meta_data( vlc_object_t *p_this, lua_State *p_state, ...@@ -349,6 +350,7 @@ void vlclua_read_meta_data( vlc_object_t *p_this, lua_State *p_state,
if( lua_isstring( p_state, t ) ) \ if( lua_isstring( p_state, t ) ) \
{ \ { \
psz_value = lua_tostring( p_state, t ); \ psz_value = lua_tostring( p_state, t ); \
EnsureUTF8( psz_value ); \
msg_Dbg( p_this, #b ": %s", psz_value ); \ msg_Dbg( p_this, #b ": %s", psz_value ); \
input_item_Set ## b ( p_input, psz_value ); \ input_item_Set ## b ( p_input, psz_value ); \
} \ } \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment