]> git.cworth.org Git - sup/commitdiff
use BufferManager.shell_out to call run-mailcap instead of system
authorBenoît PIERRE <benoit.pierre@gmail.com>
Tue, 11 Aug 2009 22:09:41 +0000 (00:09 +0200)
committerWilliam Morgan <wmorgan-sup@masanjin.net>
Fri, 14 Aug 2009 20:12:11 +0000 (13:12 -0700)
This ensure ncurses state is correctly restored upon command completion.

lib/sup/message-chunks.rb

index 4c947e15e5e83a51bc18ad404ed1d114beb2e2ae..1910abd064ee9416cefdca0bdb83f308ebed23bc 100644 (file)
@@ -133,7 +133,7 @@ EOS
     def view_default! path
       cmd = "/usr/bin/run-mailcap --action=view '#{@content_type}:#{path}'"
       Redwood::log "running: #{cmd.inspect}"
-      system cmd
+      BufferManager.shell_out(cmd)
       $? == 0
     end