]> git.notmuchmail.org Git - sup/commitdiff
sup-sync: don't save the index and sources if an error occurred
authorWilliam Morgan <wmorgan-sup@masanjin.net>
Fri, 25 Jan 2008 04:42:37 +0000 (20:42 -0800)
committerWilliam Morgan <wmorgan-sup@masanjin.net>
Fri, 25 Jan 2008 04:42:37 +0000 (20:42 -0800)
If the error was caused by a particular message, saving the source file
will move the pointer past the message, so it will never get added.

bin/sup-sync

index 0acb8eddca342bacad9b1a96ece53150fa1b6d8b..611afc4c6ccdfbd42120fcd7071216ac98fc72aa 100644 (file)
@@ -238,7 +238,7 @@ rescue Exception => e
   File.open("sup-exception-log.txt", "w") { |f| f.puts e.backtrace }
   raise
 ensure
-  index.save
+  #index.save # actually, don't want to save!
   Redwood::finish
   index.unlock
 end