make sure that the validation nodes are readable and writable
This commit is contained in:
parent
f79dbc23bf
commit
ba27bab1b2
1 changed files with 5 additions and 0 deletions
|
@ -203,7 +203,12 @@ const char *fgValidatePath (const char *str, bool write)
|
|||
static SGPropertyNode_ptr r, w;
|
||||
if (!r) {
|
||||
r = fgGetNode("/sim/paths/validate/read", true);
|
||||
r->setAttribute(SGPropertyNode::READ, true);
|
||||
r->setAttribute(SGPropertyNode::WRITE, true);
|
||||
|
||||
w = fgGetNode("/sim/paths/validate/write", true);
|
||||
w->setAttribute(SGPropertyNode::READ, true);
|
||||
w->setAttribute(SGPropertyNode::WRITE, true);
|
||||
}
|
||||
SGPropertyNode *prop = write ? w : r;
|
||||
prop->setStringValue(str);
|
||||
|
|
Loading…
Reference in a new issue