Prevent double free in mar_sign.c

This commit is contained in:
wolfbeast 2018-12-13 22:15:37 +01:00 committed by Roy Tam
commit a959f4717e

View file

@ -534,6 +534,7 @@ extract_signature(const char *src, uint32_t sigIndex, const char * dest)
for (i = 0; i <= sigIndex; i++) {
/* Avoid leaking while skipping signatures */
free(extractedSignature);
extractedSignature = NULL;
/* skip past the signature algorithm ID */
if (fseeko(fpSrc, sizeof(uint32_t), SEEK_CUR)) {