aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/url.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/url.c b/lib/url.c
index 7106d46d4..552be9468 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -3400,9 +3400,8 @@ ConnectionExists(struct Curl_easy *data,
*/
if((check->localport != needle->localport) ||
(check->localportrange != needle->localportrange) ||
- !check->localdev ||
- !needle->localdev ||
- strcmp(check->localdev, needle->localdev))
+ (needle->localdev &&
+ (!check->localdev || strcmp(check->localdev, needle->localdev))))
continue;
}