From 70385842df0c68c4e7e7eeb4531f703330edb831 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Fri, 28 Feb 2014 10:40:41 +0100 Subject: [PATCH] Add missing copy ctor for Javascript Code Template class. --- Source/Modules/javascript.cxx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Source/Modules/javascript.cxx b/Source/Modules/javascript.cxx index 7b153c66c..748043619 100644 --- a/Source/Modules/javascript.cxx +++ b/Source/Modules/javascript.cxx @@ -86,6 +86,8 @@ public: Template(const String *code, const String *templateName); + Template(const Template& other); + ~Template(); String *str(); @@ -620,7 +622,6 @@ Template JSEmitter::getTemplate(const String *name) { } Template t(templ, name); - return t; } @@ -2441,6 +2442,11 @@ Template& Template::pretty_print(DOH *doh) { return *this; } +Template::Template(const Template& t) { + code = NewString(t.code); + templateName = NewString(t.templateName); +} + void Template::operator=(const Template& t) { Delete(code); Delete(templateName);