summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-07-15 14:43:10 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-07-15 14:43:10 +0000
commit22016364f2c8b8ccccb40a58684bbb681133aade (patch)
treef70cb47aabf607165897d5d4d44354e2880aa70f /src
parent5f08261c0f9c9bb9b40962baef2ea9d9318d19f0 (diff)
passing error from the internal request outside
git-svn-id: http://svn.miranda-ng.org/main/trunk@5367 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src')
-rw-r--r--src/modules/netlib/netlibhttp.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modules/netlib/netlibhttp.cpp b/src/modules/netlib/netlibhttp.cpp
index b79d72d202..5830198596 100644
--- a/src/modules/netlib/netlibhttp.cpp
+++ b/src/modules/netlib/netlibhttp.cpp
@@ -709,7 +709,7 @@ INT_PTR NetlibHttpFreeRequestStruct(WPARAM, LPARAM lParam)
return 0;
}
if (nlhr->headers) {
- for (int i=0; i<nlhr->headersCount; i++) {
+ for (int i=0; i < nlhr->headersCount; i++) {
NETLIBHTTPHEADER &p = nlhr->headers[i];
mir_free(p.szName);
mir_free(p.szValue);
@@ -879,6 +879,7 @@ INT_PTR NetlibHttpTransaction(WPARAM wParam, LPARAM lParam)
}
if (NetlibHttpSendRequest((WPARAM)nlc, (LPARAM)&nlhrSend) == SOCKET_ERROR) {
if ( !doneUserAgentHeader || !doneAcceptEncoding) mir_free(nlhrSend.headers);
+ nlhr->resultCode = nlhrSend.resultCode;
NetlibCloseHandle((WPARAM)nlc, 0);
return 0;
}