[vlc-commits] live555: fix invalid conversion error

Edward Wang git at videolan.org
Tue Mar 5 09:42:55 CET 2013


vlc | branch: master | Edward Wang <edward.c.wang at compdigitec.com> | Sun Mar  3 19:35:03 2013 +0000| [ba28c2861d271857925183dac0b6443fd5461296] | committer: Sébastien Escudier

live555: fix invalid conversion error

../../../modules/access/live555.cpp:2154:64: error: invalid conversion from 'char const*' to 'char*' [-fpermissive]
../../../contrib/arm-linux-androideabi/include/Base64.hh:28:16: error:   initializing argument 1 of 'unsigned char* base64Decode(char*, unsigned int&, Boolean)' [-fpermissive]

base64Decode appears to be defined as unsigned char* base64Decode(char* in, unsigned& resultSize, Boolean trimTrailingZeros);

Signed-off-by: Sébastien Escudier <sebastien-devel at celeos.eu>

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

 modules/access/live555.cpp |    6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/modules/access/live555.cpp b/modules/access/live555.cpp
index 2344e40..419f669 100644
--- a/modules/access/live555.cpp
+++ b/modules/access/live555.cpp
@@ -2151,7 +2151,13 @@ static uint8_t *parseVorbisConfigStr( char const* configStr,
     configSize = 0;
     if( configStr == NULL || *configStr == '\0' )
         return NULL;
+#if LIVEMEDIA_LIBRARY_VERSION_INT >= 1332115200 // 2012.03.20
     unsigned char *p_cfg = base64Decode( configStr, configSize );
+#else
+    char* configStr_dup = strdup( configStr );
+    unsigned char *p_cfg = base64Decode( configStr_dup, configSize );
+    free( configStr_dup );
+#endif
     uint8_t *p_extra = NULL;
     /* skip header count, ident number and length (cf. RFC 5215) */
     const unsigned int headerSkip = 9;



More information about the vlc-commits mailing list