[issue] blank dive->location values update from a newly set location value

Linus Torvalds torvalds at linux-foundation.org
Wed Nov 2 22:08:13 PDT 2011

On Wed, Nov 2, 2011 at 9:53 PM, Dirk Hohndel <dirk at hohndel.org> wrote:
> I poked around as well. It seems to have a quite stubborn memory of the
> last item that was active. Even manually setting the active item to NULL
> doesn't sway it.

Yeah, I found the same thing.

And it's only the empty string that is special. Crazy. I can literally
make things work by using a single space instead (and then removing
the space on read).

And even the empty string is only special when that thing is
*selected*, as far as I can tell. So there's some magic combination
about empty strings and being the currently active text entry, which
caches the value even across setting it.

I'll commit that nasty space-setting hack for now, maybe somebody can
figure out what the magic gtk incantation is for those
gtk_combo_box_entry things.

> We need to get these location/buddy/divemaster_changed variables to work
> again, I guess... right now they are bogus as they are only initialized
> to 1 and never cleared (or set). But I couldn't figure out where to that
> when I poked around...

No, we should just get rid of those variables entirely. They aren't
useful anyway. The one that matters is the local variable "changed",
and that's maintained correctly.


More information about the subsurface mailing list