From 264edc470d5bcc8328b8d2d9ee4f7bc1cad0a3ae Mon Sep 17 00:00:00 2001 From: mfranz Date: Mon, 8 May 2006 14:53:23 +0000 Subject: [PATCH] ignore spaces after the colon in "@insert 3: ebase" --- src/Autopilot/route_mgr.cxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/Autopilot/route_mgr.cxx b/src/Autopilot/route_mgr.cxx index 654976e1d..de42860f2 100644 --- a/src/Autopilot/route_mgr.cxx +++ b/src/Autopilot/route_mgr.cxx @@ -383,7 +383,11 @@ void FGRouteMgr::Listener::valueChanged(SGPropertyNode *prop) else if (!strncmp(s, "@insert", 7)) { char *r; int pos = strtol(s + 7, &r, 10); - if (*r++ == ':' && *r) + if (*r++ != ':') + return; + while (isspace(*r)) + r++; + if (*r) mgr->new_waypoint(r, pos); } else mgr->new_waypoint(s);