From da1d6e97f63e53f26b92c6709fed6423070e10c9 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Tue, 26 Dec 2017 14:10:49 -0800 Subject: Cleanup: avoid memory leak Coverity CID 208337 Signed-off-by: Dirk Hohndel --- core/libdivecomputer.c | 1 + 1 file changed, 1 insertion(+) (limited to 'core/libdivecomputer.c') diff --git a/core/libdivecomputer.c b/core/libdivecomputer.c index fde142e0d..70b747114 100644 --- a/core/libdivecomputer.c +++ b/core/libdivecomputer.c @@ -804,6 +804,7 @@ static int dive_cb(const unsigned char *data, unsigned int size, if (!devdata->force_download && find_dive(&dive->dc)) { const char *date_string = get_dive_date_c_string(dive->when); dev_info(devdata, translate("gettextFromC", "Already downloaded dive at %s"), date_string); + free((void *)date_string); goto error_exit; } -- cgit v1.2.3-70-g09d2