[mutt] 01/03: Backport a fix for the sidebar from neomutt git.

Faidon Liambotis paravoid at moszumanska.debian.org
Mon Jul 25 16:26:29 UTC 2016


This is an automated email from the git hooks/post-receive script.

paravoid pushed a commit to branch master
in repository mutt.

commit 4d0016a6b50592c3bfd00a3ecd0438d1f7889d57
Author: Faidon Liambotis <paravoid at debian.org>
Date:   Mon Jul 25 18:42:09 2016 +0300

    Backport a fix for the sidebar from neomutt git.
---
 debian/changelog                                   |  1 +
 .../neomutt-devel/imap-sidebar-update-bug.patch    | 46 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 3 files changed, 48 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index b4db57d..d4f104d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,7 @@ mutt (1.6.2-1) UNRELEASED; urgency=medium
 
   * New upstream release.
   * New upstream NeoMutt release, 2016-07-23.
+    - Backport a fix for the sidebar from neomutt git.
   * Ship our patched Muttrc instead of the stock, non-generated Muttrc,
     something that regressed with 1.6.1-2. (Closes: #830692, #830695)
 
diff --git a/debian/patches/neomutt-devel/imap-sidebar-update-bug.patch b/debian/patches/neomutt-devel/imap-sidebar-update-bug.patch
new file mode 100644
index 0000000..0af9944
--- /dev/null
+++ b/debian/patches/neomutt-devel/imap-sidebar-update-bug.patch
@@ -0,0 +1,46 @@
+From cda6311195c7ef43818c752d4fb7fcba88d97f37 Mon Sep 17 00:00:00 2001
+From: Richard Russon <rich at flatcap.org>
+Date: Mon, 25 Jul 2016 12:57:19 +0100
+Subject: [PATCH] Fix imap/sidebar update bug
+
+The sidebar's inbox occasionally shows zero/wrong value until the next
+mail_check_stats event.
+
+If IMAP hasn't been asked for MESSAGES, don't update BUFFY->msg_count.
+---
+ imap/command.c | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/imap/command.c b/imap/command.c
+index b5c896d..235e71a 100644
+--- a/imap/command.c
++++ b/imap/command.c
+@@ -901,6 +901,7 @@ static void cmd_parse_status (IMAP_DATA* idata, char* s)
+   unsigned int olduv, oldun;
+   long litlen;
+   short new = 0;
++  short new_msg_count = 0;
+ 
+   mailbox = imap_next_word (s);
+ 
+@@ -940,7 +941,10 @@ static void cmd_parse_status (IMAP_DATA* idata, char* s)
+     count = strtol (value, &value, 10);
+ 
+     if (!ascii_strncmp ("MESSAGES", s, 8))
++    {
+       status->messages = count;
++      new_msg_count = 1;
++    }
+     else if (!ascii_strncmp ("RECENT", s, 6))
+       status->recent = count;
+     else if (!ascii_strncmp ("UIDNEXT", s, 7))
+@@ -1019,7 +1023,8 @@ static void cmd_parse_status (IMAP_DATA* idata, char* s)
+           SidebarNeedsRedraw = 1;
+ #endif
+         inc->new = new;
+-        inc->msg_count  = status->messages;
++	if (new_msg_count)
++		inc->msg_count = status->messages;
+         inc->msg_unread = status->unseen;
+ 
+ 	if (inc->new)
diff --git a/debian/patches/series b/debian/patches/series
index 548e4ba..6857e86 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,5 @@
 neomutt-20160723.patch
+neomutt-devel/imap-sidebar-update-bug.patch
 neomutt-devel/sensible-browser.patch
 features/809802_timeout_hook.patch
 features/multiple-fcc.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mutt/mutt.git



More information about the pkg-mutt-commits mailing list