diff options
author | Lubomir I. Ivanov <neolit123@gmail.com> | 2015-11-03 14:29:36 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-11-03 07:44:56 -0800 |
commit | 048c5e01b14b2388841993165db26c612f0c3fe4 (patch) | |
tree | d44a896e5f398208e4d18a5e3ac363d5bff64b04 /subsurface-core | |
parent | 05ca5051e9515239eb320f404a555165d618991c (diff) | |
download | subsurface-048c5e01b14b2388841993165db26c612f0c3fe4.tar.gz |
subsurfacestartup.c: don't double free 'default_filename'
'default_filename' is obtained from system_default_filename()
but system_default_filename() returns a static pointer
the HEAP memory of which is handled in main().
Remove the free() for 'default_filename' free_prefs()
to prevent a double free().
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface-core')
-rw-r--r-- | subsurface-core/subsurfacestartup.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/subsurface-core/subsurfacestartup.c b/subsurface-core/subsurfacestartup.c index 0bde2a070..13cbbfa3f 100644 --- a/subsurface-core/subsurfacestartup.c +++ b/subsurface-core/subsurfacestartup.c @@ -311,7 +311,6 @@ void copy_prefs(struct preferences *src, struct preferences *dest) */ void free_prefs(void) { - free((void*)prefs.default_filename); free((void*)prefs.default_cylinder); free((void*)prefs.divelist_font); free((void*)prefs.cloud_storage_password); |