From 389426e3d0d8b3b47cdc1ff18eb5a9a00a766615 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Thu, 19 Sep 2019 09:29:02 +0200 Subject: url: remove dead code Fixes warning detected by PVS-Studio Fixes #4374 --- lib/url.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/lib/url.c b/lib/url.c index e4c1ac838..e4c47930a 100644 --- a/lib/url.c +++ b/lib/url.c @@ -2761,13 +2761,6 @@ static CURLcode set_login(struct connectdata *conn) result = CURLE_OUT_OF_MEMORY; } - /* if there's a user without password, consider password blank */ - if(conn->user && !conn->passwd) { - conn->passwd = strdup(""); - if(!conn->passwd) - result = CURLE_OUT_OF_MEMORY; - } - return result; } -- cgit v1.2.1