llcache: Free existing chain if we get a new one
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
This commit is contained in:
parent
114dd37c6e
commit
b4c99f9e57
|
@ -3078,6 +3078,11 @@ static void llcache_fetch_callback(const fetch_msg *msg, void *p)
|
|||
case FETCH_CERTS:
|
||||
/* Certificate information from the fetch */
|
||||
|
||||
if (object->chain != NULL) {
|
||||
cert_chain_free(object->chain);
|
||||
object->chain = NULL;
|
||||
}
|
||||
|
||||
/* Persist the chain onto our object */
|
||||
error = cert_chain_dup(msg->data.chain, &object->chain);
|
||||
if (error != NSERROR_OK) {
|
||||
|
|
Loading…
Reference in New Issue