From: ThorstenB Date: Sat, 7 Jul 2012 14:05:02 +0000 (+0200) Subject: Suppress unnecessary "failed alias" warnings X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=51a17a7a0fd543a5990d8f2345bf01ac34b4adab;p=simgear.git Suppress unnecessary "failed alias" warnings when requested alias matches existing alias anyway (identical aliases can be created on repeated sim resets) --- diff --git a/simgear/props/props.cxx b/simgear/props/props.cxx index 26a6c85e..d690cbe6 100644 --- a/simgear/props/props.cxx +++ b/simgear/props/props.cxx @@ -797,9 +797,11 @@ SGPropertyNode::alias (SGPropertyNode * target) else if (_type == props::ALIAS) { + if (_value.alias == target) + return true; // ok, identical alias requested SG_LOG(SG_GENERAL, SG_ALERT, "Failed to create alias at " << target->getPath() << ". " - "Source "<< getPath() << " is also an alias. Unsupported recursion."); + "Source "<< getPath() << " is already aliasing another property."); } else if (_tied)