From: mfranz Date: Mon, 19 Feb 2007 20:52:55 +0000 (+0000) Subject: fix set command: allow strings to contain spaces X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=6c95d65afae8314b61c03300292b50005cb3b2e6;p=flightgear.git fix set command: allow strings to contain spaces --- diff --git a/src/Network/props.cxx b/src/Network/props.cxx index af23f44b3..234728020 100644 --- a/src/Network/props.cxx +++ b/src/Network/props.cxx @@ -272,10 +272,10 @@ PropsChannel::foundTerminator() } else if ( command == "set" ) { if ( tokens.size() >= 2 ) { string value, tmp; - if ( tokens.size() == 3 ) { - value = tokens[2]; - } else { - value = ""; + for (unsigned int i = 2; i < tokens.size(); i++) { + if (i > 2) + value += " "; + value += tokens[i]; } node->getNode( tokens[1].c_str(), true ) ->setStringValue(value.c_str());