Skip to content

Remove memory leak on multiple calls to initCertStore#7021

Merged
earlephilhower merged 3 commits intoesp8266:masterfrom
earlephilhower:bsslcs
Jan 17, 2020
Merged

Remove memory leak on multiple calls to initCertStore#7021
earlephilhower merged 3 commits intoesp8266:masterfrom
earlephilhower:bsslcs

Conversation

@earlephilhower
Copy link
Collaborator

In some cases, initCertStore may need to be called multiple times
(i.e. to update certs w/oa reboot). In that case, the saved file names
leaked when the new ones were malloc()'d.

Fix by freeing the old strings, if present.

In some cases, `initCertStore` may need to be called multiple times
(i.e. to update certs w/oa reboot).  In that case, the saved file names
leaked when the new ones were `malloc()`'d.

Fix by freeing the old strings, if present.
@earlephilhower earlephilhower added this to the 2.7.0 milestone Jan 17, 2020
@earlephilhower earlephilhower merged commit 00440cd into esp8266:master Jan 17, 2020
@earlephilhower earlephilhower deleted the bsslcs branch January 17, 2020 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant