[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[sup-devel] Fixed bug with messages not being signed.
Found the bug that stopped people signing email. Needed to use merge!
rather than merge. Real slap on head moment.
I've committed it to the (existing) gpgme branch and to next.
Hamish Downer
Full patch is:
commit 42149329b37af5e3fc0183367521999c479b7881
Author: Hamish Downer <dmishd@gmail.com>
Date: Sun Jan 30 22:44:05 2011 +0000
Fixed the bug that stopped emails being signed.
Schoolboy error - needed merge! rather than merge
diff --git a/lib/sup/crypto.rb b/lib/sup/crypto.rb
index e532261..5f1b730 100644
--- a/lib/sup/crypto.rb
+++ b/lib/sup/crypto.rb
@@ -57,7 +57,7 @@ EOS
return unknown_status(cant_find_gpgme) unless @gpgme_present
gpg_opts = {:protocol => GPGME::PROTOCOL_OpenPGP, :armor => true, :textmode => true}
- gpg_opts.merge(gen_sign_user_opts(from))
+ gpg_opts.merge!(gen_sign_user_opts(from))
gpg_opts = HookManager.run("gpg-options",
{:operation => "sign", :options => gpg_opts}) || gpg_opts
@@ -82,8 +82,8 @@ EOS
gpg_opts = {:protocol => GPGME::PROTOCOL_OpenPGP, :armor => true, :textmode => true}
if sign
- gpg_opts.merge(gen_sign_user_opts(from))
- gpg_opts.merge({:sign => true})
+ gpg_opts.merge!(gen_sign_user_opts(from))
+ gpg_opts.merge!({:sign => true})
end
gpg_opts = HookManager.run("gpg-options",
{:operation => "encrypt", :options => gpg_opts}) || gpg_opts
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel