[PATCH 4/4] Fix memory leaks related to dive_trip->location

Lubomir I. Ivanov neolit123 at gmail.com
Mon Oct 1 16:04:13 PDT 2012


On 2 October 2012 01:52, Lubomir I. Ivanov <neolit123 at gmail.com> wrote:
> From: "Lubomir I. Ivanov" <neolit123 at gmail.com>
> When creating a new dive_trip from a dive, we should probably
> always copy the location via strdup(). However we then have to take
> care of the de-allocation in divelist.c:delete_trip()
> and gtk-gui.c:file_close().
>

i was wondering if this makes any sense to do (e.g. always strdup()),
since i don't understand very well how the "location" autocomplete
list works or if its even related to this. but perhaps its better for
a dive_trip->location not to be the same as a dive->location.

lubomir
--


More information about the subsurface mailing list