[balsa] Clear a GSource id before returning



commit def5e2fc6d3416998dd6fe93ec722dbc3996f6ce
Author: Peter Bloomfield <PeterBloomfield bellsouth net>
Date:   Sun May 14 11:12:58 2017 -0400

    Clear a GSource id before returning
    
        * libbalsa/imap/imap-handle.c (idle_start): clear
          ImapMboxHandle::enable_idle_id before returning FALSE.

 ChangeLog                   |    5 +++++
 libbalsa/imap/imap-handle.c |    2 +-
 2 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 04718aa..c0e5f16 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2017-05-14  Peter Bloomfield  <pbloomfield bellsouth net>
+
+       * libbalsa/imap/imap-handle.c (idle_start): clear
+         ImapMboxHandle::enable_idle_id before returning FALSE.
+
 2017-05-04  Peter Bloomfield  <pbloomfield bellsouth net>
 
        * libbalsa/mailbox_mbox.c (parse_mailbox): try to recover when
diff --git a/libbalsa/imap/imap-handle.c b/libbalsa/imap/imap-handle.c
index 1f91a42..9abc84e 100644
--- a/libbalsa/imap/imap-handle.c
+++ b/libbalsa/imap/imap-handle.c
@@ -441,7 +441,7 @@ idle_start(gpointer data)
   if(!g_mutex_trylock(&h->mutex))
     return TRUE;/* Don't block, just try again later. */
   IMAP_REQUIRED_STATE3(h, IMHS_CONNECTED, IMHS_AUTHENTICATED,
-                       IMHS_SELECTED, FALSE);
+                       IMHS_SELECTED, (h->idle_enable_id = 0, FALSE));
 
   asyncno = imap_make_tag(tag); sio_write(h->sio, tag, strlen(tag));
   sio_write(h->sio, " IDLE\r\n", 7); sio_flush(h->sio);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]