From 1503bcb12ec9ae775a0b3435c9f2dfdd5204e09e Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Tue, 17 Sep 2019 12:30:31 +0200 Subject: [PATCH] tty-ask-pwd-agent: minor simplification by using FOREACH_DIRENT instead of FOREACH_DIRENT_ALL --- src/tty-ask-password-agent/tty-ask-password-agent.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/tty-ask-password-agent/tty-ask-password-agent.c b/src/tty-ask-password-agent/tty-ask-password-agent.c index f57f0ec261b..72b04e6f0e7 100644 --- a/src/tty-ask-password-agent/tty-ask-password-agent.c +++ b/src/tty-ask-password-agent/tty-ask-password-agent.c @@ -462,7 +462,7 @@ static int process_password_files(void) { return log_error_errno(errno, "Failed to open /run/systemd/ask-password: %m"); } - FOREACH_DIRENT_ALL(de, d, return log_error_errno(errno, "Failed to read directory: %m")) { + FOREACH_DIRENT(de, d, return log_error_errno(errno, "Failed to read directory: %m")) { _cleanup_free_ char *p = NULL; int q; @@ -472,9 +472,6 @@ static int process_password_files(void) { if (de->d_type != DT_REG) continue; - if (hidden_or_backup_file(de->d_name)) - continue; - if (!startswith(de->d_name, "ask.")) continue; -- 2.47.3