aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMarc Hoersken <info@marc-hoersken.de>2014-01-05 20:01:33 +0100
committerMarc Hoersken <info@marc-hoersken.de>2014-01-05 20:01:33 +0100
commit61312fe66f019bc48055f54f2647b8ce55acc014 (patch)
tree4281bfbbc17df9b448e466069257b7721f84698f /lib
parent149e0c8d104bf6b924e68902c2029c009b6be93d (diff)
multi.c: fix possible dereference of null pointer
Diffstat (limited to 'lib')
-rw-r--r--lib/multi.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/multi.c b/lib/multi.c
index ebee674dd..698a99eeb 100644
--- a/lib/multi.c
+++ b/lib/multi.c
@@ -2162,10 +2162,12 @@ static CURLMcode multi_socket(struct Curl_multi *multi,
/* walk through each easy handle and do the socket state change magic
and callbacks */
- data=multi->easyp;
- while(data) {
- singlesocket(multi, data);
- data = data->next;
+ if(result != CURLM_BAD_HANDLE) {
+ data=multi->easyp;
+ while(data) {
+ singlesocket(multi, data);
+ data = data->next;
+ }
}
/* or should we fall-through and do the timer-based stuff? */