From fe51ed5887c00aa2b403dc9f9b8c4521a867d908 Mon Sep 17 00:00:00 2001 From: rswindell <> Date: Sun, 5 May 2019 11:06:52 +0000 Subject: [PATCH] Clear the new convenience pointers: text_subtype and text_charset in clear_convenience_ptrs() - otherwise they can be double-freed when the message (smbmsg_t) is copied with smb_copymsgmem(). --- src/smblib/smblib.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/smblib/smblib.c b/src/smblib/smblib.c index 95bba4a047..10662bf50d 100644 --- a/src/smblib/smblib.c +++ b/src/smblib/smblib.c @@ -914,6 +914,8 @@ static void clear_convenience_ptrs(smbmsg_t* msg) msg->newsgroups=NULL; msg->mime_version=NULL; msg->content_type=NULL; + msg->text_subtype=NULL; + msg->text_charset=NULL; msg->ftn_msgid=NULL; msg->ftn_reply=NULL; -- GitLab