From a19fefb0706f939d2df7a76704ee549fecb1c4fd Mon Sep 17 00:00:00 2001 From: Eric Gallager Date: Mon, 12 Feb 2018 01:42:47 -0500 Subject: build: add picky compiler warning flags for gcc 6 and 7 --- lib/mime.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lib/mime.c') diff --git a/lib/mime.c b/lib/mime.c index 89819a935..ce56d7873 100644 --- a/lib/mime.c +++ b/lib/mime.c @@ -1193,7 +1193,10 @@ CURLcode Curl_mime_duppart(curl_mimepart *dst, const curl_mimepart *src) } /* Duplicate other fields. */ - dst->encoder = src->encoder; + if(dst != NULL) + dst->encoder = src->encoder; + else + res = CURLE_WRITE_ERROR; if(!res) res = curl_mime_type(dst, src->mimetype); if(!res) -- cgit v1.2.3