From: Peter Howkins Date: Sat, 11 Aug 2018 00:18:45 +0000 (+0100) Subject: libDtHelp: Cov 89129 and 88355 X-Git-Tag: 2.3.0a~29 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=f14e247a412cc5ba406974b5f79435542c1e8934;p=oweals%2Fcde.git libDtHelp: Cov 89129 and 88355 --- diff --git a/cde/lib/DtHelp/AccessSDL.c b/cde/lib/DtHelp/AccessSDL.c index 8d6d470f..1ba55565 100644 --- a/cde/lib/DtHelp/AccessSDL.c +++ b/cde/lib/DtHelp/AccessSDL.c @@ -1381,8 +1381,11 @@ _DtHelpCeGetSdlDocStamp( if (ret_time != NULL) *ret_time = timestamp; - if (result == 0 && (docId == NULL || timestamp == NULL)) + if (result == 0 && (docId == NULL || timestamp == NULL)) { + free(docId); /* Incase only one of them is NULL */ + free(timestamp); /* " */ return -1; + } return result; }