sup

A curses threads-with-tags style email client

sup.git

git clone https://supmua.dev/git/sup/
commit 1728fa29d1fcad67ae4353d825becff039a8dff9
parent 9efb32fd7177199c7af7c46c3a3bcd994ab80893
Author: Matthieu Rakotojaona <matthieu.rakotojaona@gmail.com>
Date:   Tue, 23 Jul 2013 21:20:17 +0200

Launch a new thread inside trap

Diffstat:
M bin/sup | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/bin/sup b/bin/sup
@@ -158,7 +158,11 @@ begin
 
   $die = false
   trap("TERM") { |x| $die = true }
-  trap("WINCH") { |x| BufferManager.sigwinch_happened! }
+  trap("WINCH") do |x|
+   ::Thread.new do
+     BufferManager.sigwinch_happened!
+   end
+  end
 
   if(s = Redwood::SourceManager.source_for DraftManager.source_name)
     DraftManager.source = s