summaryrefslogtreecommitdiff
path: root/mailnews/compose
diff options
context:
space:
mode:
authorMatt A. Tobin <email@mattatobin.com>2019-11-10 23:34:36 -0500
committerMatt A. Tobin <email@mattatobin.com>2019-11-10 23:34:36 -0500
commit22973db5032189f97bf8ad190981d71c890bf151 (patch)
tree6742abe28ec17843e938533e42cbcd87bb4eaede /mailnews/compose
parentd80e610cd5bc6a9f6c0cc139e2f07e007fa05428 (diff)
downloaduxp-22973db5032189f97bf8ad190981d71c890bf151.tar.gz
Bug 1517464 - Fix crash in SMTP DTOR by properly initializing/testing pointer.
Tag #1273
Diffstat (limited to 'mailnews/compose')
-rw-r--r--mailnews/compose/src/nsSmtpProtocol.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/mailnews/compose/src/nsSmtpProtocol.cpp b/mailnews/compose/src/nsSmtpProtocol.cpp
index 522890c789..89607224ed 100644
--- a/mailnews/compose/src/nsSmtpProtocol.cpp
+++ b/mailnews/compose/src/nsSmtpProtocol.cpp
@@ -229,13 +229,14 @@ NS_INTERFACE_MAP_END_INHERITING(nsMsgAsyncWriteProtocol)
#endif
nsSmtpProtocol::nsSmtpProtocol(nsIURI * aURL)
: nsMsgAsyncWriteProtocol(aURL)
+ , m_dataBuf(nullptr)
{
}
nsSmtpProtocol::~nsSmtpProtocol()
{
// free our local state
- PR_Free(m_dataBuf);
+ PR_FREEIF(m_dataBuf);
}
void nsSmtpProtocol::Initialize(nsIURI * aURL)