aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/conncache.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/conncache.c b/lib/conncache.c
index 48271f751..391d44fe4 100644
--- a/lib/conncache.c
+++ b/lib/conncache.c
@@ -166,10 +166,13 @@ void Curl_conncache_remove_conn(struct conncache *connc,
if(bundle->num_connections == 0) {
conncache_remove_bundle(connc, bundle);
}
- connc->num_connections--;
- DEBUGF(infof(conn->data, "The cache now contains %d members\n",
- connc->num_connections));
+ if(connc) {
+ connc->num_connections--;
+
+ DEBUGF(infof(conn->data, "The cache now contains %d members\n",
+ connc->num_connections));
+ }
}
}