From: Thomas Roessler Date: Mon, 10 Jul 2000 16:20:48 +0000 (+0000) Subject: Fix some possible NULL pointer deferences in the RFC2047 code. X-Git-Tag: mutt-1-3-6-rel~55 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=58579a4d89843eec3f0cd2030cf29100bbe91c92;p=mutt Fix some possible NULL pointer deferences in the RFC2047 code. --- diff --git a/rfc2047.c b/rfc2047.c index 4cc43321..2020416e 100644 --- a/rfc2047.c +++ b/rfc2047.c @@ -484,7 +484,7 @@ void rfc2047_encode_string (char **pd) size_t elen; char *charsets; - if (!Charset) + if (!Charset || !*pd) return; charsets = SendCharset; @@ -669,7 +669,7 @@ void rfc2047_decode (char **pd) const char *s = *pd; size_t dlen; - if (!*s) + if (!*s || !s) return; dlen = 4 * strlen (s); /* should be enough */