#3722: rfc2047.c off-by-one and resource leak
------------------------+----------------------
Reporter: MegaManSec | Owner: mutt-dev
Type: defect | Status: new
Priority: minor | Milestone:
Component: mutt | Version:
Keywords: |
------------------------+----------------------
Hi,
In rfc2047.c in the rfc2047_decode_word function, there are two problems.
1:
636 pd = d0 = safe_malloc (strlen (s));
This may not allocate enough memory for the trailing NUL bit. May need to
take a further look as to how it is called, though.
2:
723 return rv;
leaks 'pd'. It should be freed.
--
Ticket URL: <http://dev.mutt.org/trac/ticket/3722>
Mutt <http://www.mutt.org/>
The Mutt mail user agent