From 3272b45bc53dd50e830f507e98643281d85ecab1 Mon Sep 17 00:00:00 2001 From: Alexander Harkness Date: Sat, 19 Oct 2013 21:30:54 +0100 Subject: [PATCH] Added a string reserve. --- source/WebAdmin.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/source/WebAdmin.cpp b/source/WebAdmin.cpp index a81d85f5f..d0b9648d9 100644 --- a/source/WebAdmin.cpp +++ b/source/WebAdmin.cpp @@ -402,6 +402,7 @@ AString cWebAdmin::GetHTMLEscapedString( const AString& a_Input ) // Define a string to write the output to. AString dst = ""; + dst.reserve(a_Input.length()); // Loop over input and substitute HTML characters for their alternatives. for (size_t i = 0; i < a_Input.length(); i++) {