libarchive: open_zipped() does not need to check extensions for e.g. gzip
[oweals/busybox.git] / libbb / correct_password.c
index d02d0d6a09f5a9beb7fee6b2f4013729c2a09ff4..acadf391434c4b06b52e32f24057e50bba2512e4 100644 (file)
@@ -70,13 +70,13 @@ int FAST_FUNC ask_and_check_password_extended(const struct passwd *pw,
  fake_it:
        unencrypted = bb_ask(STDIN_FILENO, timeout, prompt);
        if (!unencrypted) {
-               /* EOF (such as ^D) or error (such as ^C) */
+               /* EOF (such as ^D) or error (such as ^C) or timeout */
                return -1;
        }
        encrypted = pw_encrypt(unencrypted, correct, 1);
        r = (strcmp(encrypted, correct) == 0);
        free(encrypted);
-       memset(unencrypted, 0, strlen(unencrypted));
+       nuke_str(unencrypted);
        return r;
 }