From c5abe04923c8968c38fbca67182d7e3fbd0723d9 Mon Sep 17 00:00:00 2001
From: Tofu Linden <tofu.linden@lindenlab.com>
Date: Wed, 27 Jan 2010 15:07:04 -0800
Subject: CID-188

Checker: RESOURCE_LEAK
Function: LLTemplateParser::LLTemplateParser(LLTemplateTokenizer &)
File: /indra/llmessage/llmessagetemplateparser.cpp
---
 indra/llmessage/llmessagetemplateparser.cpp | 4 ++++
 1 file changed, 4 insertions(+)

(limited to 'indra/llmessage')

diff --git a/indra/llmessage/llmessagetemplateparser.cpp b/indra/llmessage/llmessagetemplateparser.cpp
index 283547ea00..2ddbf3e0df 100644
--- a/indra/llmessage/llmessagetemplateparser.cpp
+++ b/indra/llmessage/llmessagetemplateparser.cpp
@@ -403,6 +403,10 @@ LLTemplateParser::LLTemplateParser(LLTemplateTokenizer & tokens):
 		{
 			mMessages.push_back(templatep);
 		}
+		else
+		{
+			delete templatep;
+		}
 	}
 
 	if(!tokens.wantEOF())
-- 
cgit v1.2.3