]> git.ipfire.org Git - thirdparty/shadow.git/commitdiff
src/useradd.c: Use !strcaseeq() instead of its pattern
authorAlejandro Colomar <alx@kernel.org>
Sat, 8 Feb 2025 23:19:34 +0000 (00:19 +0100)
committerSerge Hallyn <serge@hallyn.com>
Sat, 15 Feb 2025 16:26:50 +0000 (10:26 -0600)
Signed-off-by: Alejandro Colomar <alx@kernel.org>
src/useradd.c

index e271b30e1d233beccf0a1aa8591ffab8ca76b497..ee52aafde0d72f4f3abefddf671eeb03fda45d95 100644 (file)
@@ -67,6 +67,7 @@
 #include "string/memset/memzero.h"
 #include "string/sprintf/snprintf.h"
 #include "string/sprintf/xasprintf.h"
+#include "string/strcmp/strcaseeq.h"
 #include "string/strcmp/streq.h"
 #include "string/strdup/xstrdup.h"
 #include "string/strtok/stpsep.h"
@@ -2361,7 +2362,7 @@ static void create_mail (void)
        const char    *spool;
        struct group  *gr;
 
-       if (strcasecmp(create_mail_spool, "yes") != 0)
+       if (!strcaseeq(create_mail_spool, "yes"))
                return;
 
        spool = getdef_str("MAIL_DIR");