summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2013-03-12 21:29:27 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2013-03-12 21:29:27 (GMT)
commit7a055a9d90ea3464bbdc314df423e2aa768ce2be (patch)
tree6e238f5509f47c19ac402e37e4d0743bff81d05a
parent35b7f62d3b8dfac0475b691bf8422a25523345fd (diff)
downloadpowder-7a055a9d90ea3464bbdc314df423e2aa768ce2be.zip
powder-7a055a9d90ea3464bbdc314df423e2aa768ce2be.tar.gz
More unnecessary string duplication
-rw-r--r--src/client/Client.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/client/Client.cpp b/src/client/Client.cpp
index cf1a5db..6267d91 100644
--- a/src/client/Client.cpp
+++ b/src/client/Client.cpp
@@ -121,7 +121,7 @@ void Client::Initialise(std::string proxyString)
}
if(proxyString.length())
- http_init(proxyString.c_str());
+ http_init((char*)proxyString.c_str());
else
http_init(NULL);
@@ -411,12 +411,7 @@ void Client::SetProxy(std::string proxy)
{
http_done();
if(proxy.length())
- {
- char *tempproxy = new char[proxy.length() + 1];
- std::strcpy (tempproxy, proxy.c_str());
- http_init(tempproxy);
- delete[] tempproxy;
- }
+ http_init((char*)proxy.c_str());
else
http_init(NULL);
}