Patch from Frederic Bouvier:
I had a segfault in case result.size() is 0 because result[i] is used before knowing it exists. I inverted the test and it now goes well.
This commit is contained in:
parent
276ad45d0e
commit
9af342a033
1 changed files with 1 additions and 1 deletions
|
@ -190,7 +190,7 @@ point_list calc_elevations( const string& root, const point_list& geod_nodes,
|
|||
while ( !done ) {
|
||||
// find first node with -9999 elevation
|
||||
i = 0;
|
||||
while ( (result[i].z() > -9000) && (i < (int)result.size()) ) {
|
||||
while ( (i < (int)result.size()) && (result[i].z() > -9000) ) {
|
||||
++i;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue