mirror of
https://github.com/zyedidia/micro.git
synced 2026-02-05 14:40:20 +09:00
We should cancel previously requested periodic backup (and remove this backup if it has already been created) not only when saving or closing the buffer but also in other cases when the buffer's state changes from modified to unmodified, i.e. when the user undoes all unsaved changes. Otherwise, if micro terminates abnormally before the buffer is closed, this backup will not get removed (so next time micro will suggest the user to recover this file), even though all changes to this file were successfully saved.