summaryrefslogtreecommitdiff
path: root/indra/newview/lltranslate.cpp
diff options
context:
space:
mode:
authorDave SIMmONs <simon@lindenlab.com>2011-06-08 14:53:00 -0700
committerDave SIMmONs <simon@lindenlab.com>2011-06-08 14:53:00 -0700
commit484a4733b7b361d87c6092f4f399951e84c2aacd (patch)
tree3031f4f041ffbe87f57d3a58e8ecf3bc988f439b /indra/newview/lltranslate.cpp
parent3dfb4944ed916f9a251078a2614a854b9de0315d (diff)
parent68a7c4cb83aca58e6ad9162be9e5022d6f801eac (diff)
Merge latest from lindenlab/viewer-development/
Diffstat (limited to 'indra/newview/lltranslate.cpp')
-rw-r--r--indra/newview/lltranslate.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/indra/newview/lltranslate.cpp b/indra/newview/lltranslate.cpp
index 2de7db38ed..2f60b6b90b 100644
--- a/indra/newview/lltranslate.cpp
+++ b/indra/newview/lltranslate.cpp
@@ -28,6 +28,8 @@
#include "lltranslate.h"
+#include <curl/curl.h>
+
#include "llbufferstream.h"
#include "llui.h"
#include "llversioninfo.h"
@@ -76,7 +78,9 @@ void LLTranslate::translateMessage(LLHTTPClient::ResponderPtr &result, const std
//static
void LLTranslate::getTranslateUrl(std::string &translate_url, const std::string &from_lang, const std::string &to_lang, const std::string &mesg)
{
- std::string escaped_mesg = curl_escape(mesg.c_str(), mesg.size());
+ char * curl_str = curl_escape(mesg.c_str(), mesg.size());
+ std::string const escaped_mesg(curl_str);
+ curl_free(curl_str);
translate_url = m_GoogleURL
+ escaped_mesg + m_GoogleLangSpec