summaryrefslogtreecommitdiffstats
path: root/monitor.c
AgeCommit message (Collapse)Author
2019-09-01add fallback for inotify_init1Gero Treuner
2019-04-16Convert other users of BUFFY->pathbuf to use BUFFERS.Kevin McCarthy
A few functions in browser.c, buffy.c, and monitor.c were using BUFFY->pathbuf but were potentially truncating via fixed size buffers. Convert those to use BUFFERS too. buffy_get() was creating epath and expanding it, apparently to match against expanded BUFFY list entries, was wasn't using the epath. I believe this is a bug, and have switched the comparison to epath.
2018-06-27Reset all MonitorContext state on context removal.Kevin McCarthy
Reset both the descriptor and changed flag when the current context is removed. Don't make this dependent on the context being valid or being found by monitor_resolve(), in case the context was closed due to some type of error condition.
2018-06-26Fix MonitorContextDescriptor update on removal.Kevin McCarthy
Reset the context descriptor before checking for the monitor being shared by another mailbox. Technically, it would be set properly during the next add, but it shouldn't be left incorrect.
2018-06-25Work around open mailbox monitor code check issue.Kevin McCarthy
The monitor code is too fast, and can result in all the changes for a single directory stat update being missed. Work around this issue by not recording stat time updates when the check_mailbox() is triggered by the monitor. This will cause the next subsequent check to take another look.
2018-06-10Move mutt_getch() timeout value into curs_lib.cKevin McCarthy
Change monitor.c to reference the curs_lib value, instead of vice-versa. We need to store the value for both monitor.c's poll and for mutt_monitor_ch() to perform an initial non-blocking check of ncurses' getch() buffer.
2018-06-08Spelling mistake in debug message.Vincent Lefevre
2018-06-08Give a prototype for mutt_monitor_pollVincent Lefevre
2018-06-05Quick fix for ncurses buffering issue with inotify polling.Kevin McCarthy
Ncurses does its own buffering for some character sequences, notable Esc-prefixed input. Add a non-blocking check for getch() before performing the mutt_monitor_poll() call. This is a quick fix, which I'll clean up more later.
2018-06-03Add new timeout functions to work with inotify monitors.Kevin McCarthy
The ncurses timeout() function doesn't affect the new poll inside mutt_monitor_poll(). This meant that $imap_keepalive and $timeout were not being respected when the monitor was used. Create mutt_getch_timeout(), which delegates to timeout() and sets a timeout value mutt_monitor_poll() uses too.
2018-06-03add feature file monitoring with Linux inotifyGT