[vlc-devel] [PATCH] live555: fix invalid conversion error

Edward Wang edward.c.wang at compdigitec.com
Sun Mar 3 21:35:03 CET 2013


../../../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);
---
 modules/access/live555.cpp |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

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;
-- 
1.7.5.4




More information about the vlc-devel mailing list