summaryrefslogtreecommitdiff
path: root/server
diff options
context:
space:
mode:
authorGluzskiy Alexandr <sss@sss.chaoslab.ru>2011-11-21 03:23:05 +0200
committerGluzskiy Alexandr <sss@sss.chaoslab.ru>2011-11-21 03:23:05 +0200
commite555b3102f7be659f53bc24e81bcba90d97aad81 (patch)
treebde4f42d137be234a5b7184aba722cd6274bdd13 /server
parent81a69a932806a138712e77f019d44ba1f9a43ff1 (diff)
fixed response to upload list request
fixed upload list parsing
Diffstat (limited to 'server')
-rw-r--r--server/proxy_ui_server.workspace1
-rw-r--r--server/server/config.cpp2
-rw-r--r--server/server/main.cpp4
3 files changed, 4 insertions, 3 deletions
diff --git a/server/proxy_ui_server.workspace b/server/proxy_ui_server.workspace
index 30e9c53..1917b11 100644
--- a/server/proxy_ui_server.workspace
+++ b/server/proxy_ui_server.workspace
@@ -13,6 +13,7 @@
<![CDATA[
+
]]>
</Environment>
</CodeLite_Workspace>
diff --git a/server/server/config.cpp b/server/server/config.cpp
index 2f64d42..ec21f2c 100644
--- a/server/server/config.cpp
+++ b/server/server/config.cpp
@@ -80,7 +80,7 @@ void config::load_upload_list(char *pth)
while(p2 != std::string::npos)
{
std::string line = cfg_str.substr(p1, p2-p1);
- p1 = p2+l;
+ p1 = p2+l+1;
std::string::size_type lp1 = 0, lp2 = 0;
std::string source, destination, hash;
lp1++;
diff --git a/server/server/main.cpp b/server/server/main.cpp
index da9d844..e8a4f20 100644
--- a/server/server/main.cpp
+++ b/server/server/main.cpp
@@ -432,10 +432,10 @@ void session::proto_parser(std::vector<byte>& data)
data.push_back(0x05);
for(std::list<upload_entry>::iterator it = cfg->get_upload_list()->begin(), end = cfg->get_upload_list()->end(); it != end; ++it)
{
- if(!(it->source.empty()))
+ /*if(!(it->source.empty()))
for(int i = 0; i < it->source.size(); ++ i)
data.push_back(it->source[i]);
- data.push_back('\x20');
+ data.push_back('\x20');*/
if(!(it->destination.empty()))
for(int i = 0; i < it->destination.size(); ++ i)
data.push_back(it->destination[i]);