On Friday 11 August 2006 23:43, Mathias Fröhlich wrote:
> Hi,
>
> while debugging Maik's multiplayer problems, Olaf and I experienced some
> problems in groudnetwork.cxx.
>
> At the end of the FGGroundNetwork::trance() there are two pop_back's where
> the second one poped an non existent last entry from the routesStack
> vector. We tried to avoid poping in that case by an if
> (!routesStack.empty()) guard in from of that pop_back. But with that we got
> some other problems in FGTaxiRoute::next() ...
> If we revert groundnetwork.cxx to the previous revision, those problems
> were gone.
> Any ideas?
>

I've been adding a route tracking system to the trace algorithm, so it is 
possible that a bug crept in during the change. This was done in preparation 
for adding aircraft ground proximity detection, and so I need to know which 
route each aircraft is on. The original version, in contrast, only kept track 
of the waypoints.

In the new system, there's always one route less than there are waypoints. For 
the first route one needs the start and end point of the waypoint, whereas 
for subsequent routes you only need the end point. The starting point of that  
route is defined as the end point of the previous route. 

I don't have time to investigate in depth right now, but I suspect that the 
fact that pushing back one point less onto routesStack than onto nodesStack 
is part of the problem. I'm off from work next week, and planning to work on 
this stuff, again from Tuesday onward, so I'll put investigating this problem 
on my todo list.

Btw, where did you experience these problems (which airport), and how did they 
manifest themselves? Program crashes? I've been running recent versions of 
FlightGear using the EHAM groundnetwork, and hadn't seen any problem yet. 
It's possible that it's something that only shows up at KSFO (which I haven't 
tested so much yet).

BTW, I predict that if you used the routesStack.emty() guard, the progam was 
crashing in TaxiRoute.next(), because the  (nodes.size() == (routes.size()) 
+1 condition was not met anymore. I did include a test for this condition, 
but since it was always true on my system, I commented it out.  

My estimate is that the solution is fairly easy, and I'll probably have 
something by Tuesday (I'll be out of town on the weekend). 

Thanks for reporting. 

Cheers,
Durk

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Flightgear-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to