]> granicus.if.org Git - neomutt/commitdiff
strip out once-used macro
authorRichard Russon <rich@flatcap.org>
Mon, 12 Jun 2017 17:34:15 +0000 (18:34 +0100)
committerRichard Russon <rich@flatcap.org>
Tue, 13 Jun 2017 13:56:53 +0000 (14:56 +0100)
mh.c

diff --git a/mh.c b/mh.c
index b84405dc3ada8def427b43db3183ae5fc01e25ab..c048724cc8f3e7f32136ad545bf5d41a8c5fccd0 100644 (file)
--- a/mh.c
+++ b/mh.c
@@ -1097,23 +1097,6 @@ static void maildir_delayed_parsing(struct Context *ctx, struct Maildir **md,
   int ret;
 #endif
 
-#define DO_SORT()                                                              \
-  do                                                                           \
-  {                                                                            \
-    if (!sort)                                                                 \
-    {                                                                          \
-      mutt_debug(4, "maildir: need to sort %s by inode\n", ctx->path);         \
-      p = maildir_sort(p, (size_t) -1, md_cmp_inode);                          \
-      if (!last)                                                               \
-        *md = p;                                                               \
-      else                                                                     \
-        last->next = p;                                                        \
-      sort = 1;                                                                \
-      p = skip_duplicates(p, &last);                                           \
-      snprintf(fn, sizeof(fn), "%s/%s", ctx->path, p->h->path);                \
-    }                                                                          \
-  } while (0)
-
 #ifdef USE_HCACHE
   hc = mutt_hcache_open(HeaderCache, ctx->path, NULL);
 #endif
@@ -1129,7 +1112,18 @@ static void maildir_delayed_parsing(struct Context *ctx, struct Maildir **md,
     if (!ctx->quiet && progress)
       mutt_progress_update(progress, count, -1);
 
-    DO_SORT();
+    if (!sort)
+    {
+      mutt_debug(4, "maildir: need to sort %s by inode\n", ctx->path);
+      p = maildir_sort(p, (size_t) -1, md_cmp_inode);
+      if (!last)
+        *md = p;
+      else
+        last->next = p;
+      sort = 1;
+      p = skip_duplicates(p, &last);
+      snprintf(fn, sizeof(fn), "%s/%s", ctx->path, p->h->path);
+    }
 
     snprintf(fn, sizeof(fn), "%s/%s", ctx->path, p->h->path);
 
@@ -1200,8 +1194,6 @@ static void maildir_delayed_parsing(struct Context *ctx, struct Maildir **md,
   mutt_hcache_close(hc);
 #endif
 
-#undef DO_SORT
-
   mh_sort_natural(ctx, md);
 }