mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Core: remove ASSIGNED_TRIP trip flag
The distinction between ASSIGNED_TRIP and IN_TRIP was used to prefer non-autogenerated trips on merging of dives. But owing to bit rot this seem to have worked only partially anyway: The IN_TRIP field was set in create_and_hookup_trip_from_dive() and immediately overwritten in add_dive_to_trip() called in the next line. Instead, use the trip->autogen flag to check for priority and remove the ASSIGNED_TRIP flag alltogether. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
dcb2a17b7d
commit
3b9e0b5931
4 changed files with 11 additions and 18 deletions
|
@ -254,10 +254,8 @@ void dive_end(struct parser_state *state)
|
|||
free_dive(state->cur_dive);
|
||||
else
|
||||
record_dive_to_table(state->cur_dive, state->target_table);
|
||||
if (state->cur_trip) {
|
||||
if (state->cur_trip)
|
||||
add_dive_to_trip(state->cur_dive, state->cur_trip);
|
||||
state->cur_dive->tripflag = IN_TRIP;
|
||||
}
|
||||
state->cur_dive = NULL;
|
||||
state->cur_dc = NULL;
|
||||
state->cur_location.lat.udeg = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue