[PULL REQUEST] A couple of small mods post the delmulti rework
dirk at hohndel.org
Sat Sep 29 12:32:54 PDT 2012
On Sep 29, 2012, at 12:08 PM, Dirk Hohndel wrote:
> On Sep 29, 2012, at 10:17 AM, Linus Torvalds wrote:
>> On Sat, Sep 29, 2012 at 9:57 AM, Lubomir I. Ivanov <neolit123 at gmail.com> wrote:
>>> i think i've re-imported some of the dives that were already in the
>>> list (basically grabbing a selection of "recent")
>>> at least, this was what i was trying to reproduce it with.
>> Hmm. Dive merging has some logic to take the "biggest" tripflag for a
>> merged dive (see try_to_merge()), but doesn't actually merge the trip
>> pointer itself (or update the trip counts etc).
>> So that's probably it. We've had these kinds of problems before when
>> we've introduced new semantics to dives, but forgot to teach dive
>> merging about the new stuff...
> I actually added the tripflag logic there, thinking that we didn't need to maintain the dive->divetrip but now that I think about this some more I believe I was wrong.
> Are you working on a fix or should I add that to my todo list?
Never mind. Reading through the code once more I think I understand what happened and have a very simple solution.
Pushed. Lubomir, I know you hadn't quite figured out how to reproduce this, but I'd appreciate if you tried this :-)
More information about the subsurface