mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-09-29 21:37:50 +00:00
org-crypt.el: Fix encrypt/decrypt in presence of arbitrary drawers
* lisp/org/org-crypt.el (org-encrypt-entry, org-decrypt-entry): Skip _all_ meta data before looking for PGP content. TINYCHANGE
This commit is contained in:
parent
351a0a0b0c
commit
c93983613d
|
@ -174,7 +174,7 @@ See `org-crypt-disable-auto-save'."
|
|||
(org-back-to-heading t)
|
||||
(setq-local epg-context (epg-make-context nil t t))
|
||||
(let ((start-heading (point)))
|
||||
(org-end-of-meta-data)
|
||||
(org-end-of-meta-data t)
|
||||
(unless (looking-at-p "-----BEGIN PGP MESSAGE-----")
|
||||
(let ((folded (org-invisible-p))
|
||||
(crypt-key (org-crypt-key-for-heading))
|
||||
|
@ -205,7 +205,7 @@ See `org-crypt-disable-auto-save'."
|
|||
(save-excursion
|
||||
(outline-end-of-heading)
|
||||
(org-invisible-p))))
|
||||
(org-end-of-meta-data)
|
||||
(org-end-of-meta-data t)
|
||||
(when (looking-at "-----BEGIN PGP MESSAGE-----")
|
||||
(org-crypt-check-auto-save)
|
||||
(setq-local epg-context (epg-make-context nil t t))
|
||||
|
|
Loading…
Reference in a new issue