From d1897fabf09129bcc3f7ee2d9ea2e002fd3b528c Mon Sep 17 00:00:00 2001 From: Erik Hofman Date: Tue, 27 Jul 2010 14:51:44 +0200 Subject: [PATCH] Small bugfix, the previous test always sets _property (these days) --- simgear/sound/xmlsound.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/simgear/sound/xmlsound.cxx b/simgear/sound/xmlsound.cxx index 479e3123..2a3cbfac 100644 --- a/simgear/sound/xmlsound.cxx +++ b/simgear/sound/xmlsound.cxx @@ -109,7 +109,10 @@ SGXmlSound::init(SGPropertyNode *root, SGPropertyNode *node, if ( !strcmp(type_str, "avionics") ) is_avionics = true; - _property = root->getNode(node->getStringValue("property", ""), true); + string propval = node->getStringValue("property", ""); + if (propval != "") + _property = root->getNode(propval, true); + SGPropertyNode *condition = node->getChild("condition"); if (condition != NULL) _condition = sgReadCondition(root, condition); -- 2.39.5