[vlc-commits] lib: fix shadowing and wrong variable type

Rémi Denis-Courmont git at videolan.org
Sun Sep 21 10:40:03 CEST 2014


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Sep 18 18:07:02 2014 +0300| [6226ab46871009ba21e3d6e242af5029049e50e0] | committer: Rémi Denis-Courmont

lib: fix shadowing and wrong variable type

asprintf() returns an int, not a char *.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6226ab46871009ba21e3d6e242af5029049e50e0
---

 lib/vlm.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/vlm.c b/lib/vlm.c
index aad066b..4c75ef6 100644
--- a/lib/vlm.c
+++ b/lib/vlm.c
@@ -286,7 +286,7 @@ static char* recurse_answer( vlm_message_t *p_answer, const char* psz_delim,
                 strcmp( aw_child->psz_name, "inputs" ) == 0 ||
                 strcmp( aw_child->psz_name, "options" ) == 0 )
             {
-                char *psz_recurse = recurse_answer( aw_child, psz_childdelim, 1 ),
+                char *psz_recurse = recurse_answer( aw_child, psz_childdelim, 1 );
                 i_success = asprintf( &psz_tmp, "%s[%s%s%s]%c%s",
                                       psz_response, psz_childdelim, psz_recurse,
                                       psz_delim, c_comma, psz_delim );
@@ -300,7 +300,7 @@ static char* recurse_answer( vlm_message_t *p_answer, const char* psz_delim,
              */
             else
             {
-                char *psz_recurse = recurse_answer( aw_child, psz_childdelim, 0 ),
+                char *psz_recurse = recurse_answer( aw_child, psz_childdelim, 0 );
                 i_success = asprintf( &psz_tmp, "%s{%s%s%s%s}%c%s",
                                       psz_response, psz_childdelim, psz_nametag,
                                       psz_recurse, psz_delim, c_comma, psz_delim );



More information about the vlc-commits mailing list