[xiph-commits] r18473 - icecast/trunk/ices/src

ph3-der-loewe at svn.xiph.org ph3-der-loewe at svn.xiph.org
Wed Jul 18 18:03:45 PDT 2012


Author: ph3-der-loewe
Date: 2012-07-18 18:03:45 -0700 (Wed, 18 Jul 2012)
New Revision: 18473

Modified:
   icecast/trunk/ices/src/cfgparse.c
Log:
Handle empty strings as empty strings in config, not as NULL.
This doesn't seem to break stuff but will unbreak more than just the originally
reported problem with empty passwords. However it should be considered to add
some defauls we fall back to when the string is empty. close #1875


Modified: icecast/trunk/ices/src/cfgparse.c
===================================================================
--- icecast/trunk/ices/src/cfgparse.c	2012-07-19 00:34:54 UTC (rev 18472)
+++ icecast/trunk/ices/src/cfgparse.c	2012-07-19 01:03:45 UTC (rev 18473)
@@ -66,6 +66,7 @@
     do {\
         if (x) xmlFree(x);\
         (x) = (char *)xmlNodeListGetString(doc, node->xmlChildrenNode, 1);\
+        if (!(x)) (x) = xmlStrdup("");\
     } while (0) 
 
 #define SET_INT(x) \



More information about the commits mailing list