(pgg-gpg-possibly-cache-passphrase): Fix PIN caching,
[gnus] / lisp / pgg-gpg.el
index d453abf..432f04f 100644 (file)
   (if (and pgg-cache-passphrase
           (progn
             (goto-char (point-min))
-            (re-search-forward "^\\[GNUPG:] GOOD_PASSPHRASE\\>" nil t)))
+            (re-search-forward "^\\[GNUPG:] \\(GOOD_PASSPHRASE\\>\\)\\|\\(SIG_CREATED\\)" nil t)))
       (pgg-add-passphrase-cache
        (or key
           (progn
             (goto-char (point-min))
             (if (re-search-forward
-                 "^\\[GNUPG:] NEED_PASSPHRASE \\w+ ?\\w*" nil t)
+                 "^\\[GNUPG:] NEED_PASSPHRASE\\(_PIN\\)? \\w+ ?\\w*" nil t)
                 (substring (match-string 0) -8))))
        passphrase)))
 
@@ -270,4 +270,5 @@ If optional argument SIGN is non-nil, do a combined sign and encrypt."
 
 (provide 'pgg-gpg)
 
+;;; arch-tag: 2aa5d5d8-93a0-4865-9312-33e29830e000
 ;;; pgg-gpg.el ends here