ORTS.Processes.ThreadHangException at ORTS.Traveller.DistanceTo (X3036, Vanchiglia - Nizza, Drivethrough1_notraffic, balloon loop (case 2))
Bug #1448772 reported by
Carlo Santucci
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Open Rails |
Fix Released
|
Medium
|
jeroenp |
Bug Description
When re-entering the balloon loop the program freezes.
Route can be downloaded from here http://
Logfile is attached, as well as the packaged activity. Within file GTT7000.con the trainset has to be replaced with another one, as I am no more able to provide a download link for the original trainset.
This bug is solved with patch traveller.cs.patch present in bug report https:/
Changed in or: | |
status: | New → In Progress |
assignee: | nobody → jeroenp (j-paasschens) |
summary: |
- Program freezes in balloon loop (case 2) + ORTS.Processes.ThreadHangException at ORTS.Traveller.DistanceTo (X3036, + Vanchiglia - Nizza, Drivethrough1_notraffic, balloon loop (case 2)) |
Changed in or: | |
milestone: | none → 1.0 |
importance: | Undecided → Medium |
Changed in or: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Dear all,
I confirmed this.
As James already mentioned in https:/ /bugs.launchpad .net/or/ +bug/1447222 different places that use Traveller. DistanceTo should preferably define a maximum distance to search for to prevent loops. But it is also clear that not all of these uses have a default or natural search distance. In 1447222 there is a natural distance.
So I find it very difficult to create such a distance for all possible uses (both from within Activity.cs and in other places like train.cs). But I agree with James that the traveller loopchecking is probably too complex for 1.0.
So I can fix this bug (I think), see patch. But, other places where hanging can occur due to loops are still possible.
Note, that for this bug, the DistanceTo is called in places where the activity checks on whether it is on a station or platform. I take a maximum distance of 10000 (I am assuming this means 10km). Which I would assume would cover all platforms (1km might be too small for all I know). But I cannot be sure.
A better solution for this bug would be to refactor the code for finding whether you are in a platform/station or not, and perhaps use the size of the platform/station as a natural limit. But that is certainly for after 1.0.
As said, this fix is less natural then the one in 1447222.
Note, this patch is independent of the 1447222 patch (and does not solve that bug).
Best regards. Jeroen.