From f8e9d29533250af5f575d63fae4f2f60b4e0bad6 Mon Sep 17 00:00:00 2001 From: Jani Nikula Date: Fri, 1 Sep 2017 18:53:06 +0300 Subject: [PATCH] cli/new: use the same style for fs entry loops Just to please the eyes. No functional changes. --- notmuch-new.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/notmuch-new.c b/notmuch-new.c index e011788d..c6a741fe 100644 --- a/notmuch-new.c +++ b/notmuch-new.c @@ -443,10 +443,7 @@ add_files (notmuch_database_t *notmuch, /* Pass 1: Recurse into all sub-directories. */ is_maildir = _entries_resemble_maildir (path, fs_entries, num_fs_entries); - for (i = 0; i < num_fs_entries; i++) { - if (interrupted) - break; - + for (i = 0; i < num_fs_entries && ! interrupted; i++) { entry = fs_entries[i]; /* Ignore any files/directories the user has configured to @@ -514,11 +511,7 @@ add_files (notmuch_database_t *notmuch, } /* Pass 2: Scan for new files, removed files, and removed directories. */ - for (i = 0; i < num_fs_entries; i++) - { - if (interrupted) - break; - + for (i = 0; i < num_fs_entries && ! interrupted; i++) { entry = fs_entries[i]; /* Ignore files & directories user has configured to be ignored */