thermferm/rdconfig.c

changeset 96
d08bf980ff28
parent 95
2c28afc329a5
child 101
1302abe92eb1
--- a/thermferm/rdconfig.c	Mon Jul 07 22:31:07 2014 +0200
+++ b/thermferm/rdconfig.c	Mon Jul 07 22:51:59 2014 +0200
@@ -173,7 +173,7 @@
 	syslog(LOG_NOTICE, "wrconfig: error at xmlTextWriterWriteFormatElement");
 	return 1;
     }
-    if ((rc = xmlTextWriterWriteFormatElement(writer, BAD_CAST "AIR_ADDRESS", "%s", Config.air_address)) < 0) {
+    if (Config.air_address && (rc = xmlTextWriterWriteFormatElement(writer, BAD_CAST "AIR_ADDRESS", "%s", Config.air_address)) < 0) {
 	syslog(LOG_NOTICE, "wrconfig: error at xmlTextWriterWriteFormatElement");
 	return 1;
     }

mercurial