]> snippets.scripts.mit.edu Git - Scripts/git/.git/commitdiff
barnowl/zcrypt.pl: Pass the unencrypted message to zcrypt
authorGeoffrey Thomas <geofft@mit.edu>
Wed, 20 Jan 2010 05:34:21 +0000 (00:34 -0500)
committerGeoffrey Thomas <geofft@mit.edu>
Tue, 2 Feb 2010 07:05:35 +0000 (02:05 -0500)
If barnowl has already decrypted a message, :decrypt should still work.

Signed-off-by: Geoffrey Thomas <geofft@mit.edu>
barnowl/zcrypt.pl

index 75d73a7338a18abe02519fdf4b3ac5e481c76fd0..cf864fb26e847f28d46791d2a4a5e3c517026ad2 100644 (file)
@@ -25,7 +25,7 @@ BarnOwl::new_command(decrypt => sub {
    my ($zo, $zi);
    my $pid = open2($zo, $zi, '/mit/outland/bin/zcrypt', '-D', @args) or die "Couldn't launch zcrypt\n";
    my $decrypted;
-   print $zi $msg->body . "\n";
+   print $zi $msg->fields[1] . "\n";
    close $zi;
    while (<$zo>) {
       chomp;