[vlc-devel] [PATCH] keystore: accept empty username

Thomas Guillem thomas at gllm.fr
Tue Sep 1 11:01:15 CEST 2020


The http protocol accepts empty username. Other protocols may not accept it.
This will result on a fail of the login function, leaving the possibility to
try a new login.

Fixes #25074
---
 src/misc/keystore.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/misc/keystore.c b/src/misc/keystore.c
index b5b4cc7e50e..d58e8dea982 100644
--- a/src/misc/keystore.c
+++ b/src/misc/keystore.c
@@ -196,8 +196,7 @@ find_closest_path(vlc_keystore_entry *p_entries, unsigned i_count,
 static bool
 is_credential_valid(vlc_credential *p_credential)
 {
-    if (p_credential->psz_username && *p_credential->psz_username != '\0'
-     && p_credential->psz_password)
+    if (p_credential->psz_username && p_credential->psz_password)
         return true;
     p_credential->psz_password = NULL;
     return false;
-- 
2.28.0



More information about the vlc-devel mailing list