summaryrefslogtreecommitdiff
path: root/pjlib-util/src
diff options
context:
space:
mode:
authorLiong Sauw Ming <ming@teluu.com>2010-06-29 17:02:59 +0000
committerLiong Sauw Ming <ming@teluu.com>2010-06-29 17:02:59 +0000
commit2a827d31c2627cacbfd90424e6f3e85c4f7bfdc0 (patch)
treedf9c64a1a38e0a019f790750dd92fdf26812b2dc /pjlib-util/src
parent30a0510e97b01244ee21b787ae4f4cd70bcc6559 (diff)
Misc(re #1068): fixed crash because pj_http_req may now be destroyed after calling on_complete callback.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@3228 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib-util/src')
-rw-r--r--pjlib-util/src/pjlib-util/http_client.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/pjlib-util/src/pjlib-util/http_client.c b/pjlib-util/src/pjlib-util/http_client.c
index 05b5c50f..359f31ec 100644
--- a/pjlib-util/src/pjlib-util/http_client.c
+++ b/pjlib-util/src/pjlib-util/http_client.c
@@ -28,7 +28,7 @@
#include <pjlib-util/errno.h>
#include <pjlib-util/scanner.h>
-#if 0
+#if 1
/* Enable some tracing */
#define THIS_FILE "http_client.c"
#define TRACE_(arg) PJ_LOG(3,arg)
@@ -327,9 +327,9 @@ static pj_bool_t http_on_data_read(pj_activesock_t *asock,
hreq->response.size = 0;
if (rem > 0 || hreq->response.content_length == 0)
- http_on_data_read(asock, (rem == 0 ? NULL:
- (char *)data + size - rem),
- rem, PJ_SUCCESS, NULL);
+ return http_on_data_read(asock, (rem == 0 ? NULL:
+ (char *)data + size - rem),
+ rem, PJ_SUCCESS, NULL);
}
return PJ_TRUE;