]> git.notmuchmail.org Git - notmuch/blobdiff - emacs/notmuch-show.el
Use `without-restriction` in `with-temporary-notmuch-message-buffer`
[notmuch] / emacs / notmuch-show.el
index 4cc5aa57d91cc204b2800bf8e38c75f057231dc5..14e3c698693e1c1954a5f3682532083e05ab5150 100644 (file)
@@ -864,7 +864,7 @@ will return nil if the CID is unknown or cannot be retrieved."
                    (unless (icalendar-import-buffer file t)
                      (error "Icalendar import error. %s"
                             "See *icalendar-errors* for more information"))
-                   (set-buffer (get-file-buffer file))
+                   (set-buffer (find-buffer-visiting file))
                    (setq result (buffer-substring (point-min) (point-max)))
                    (set-buffer-modified-p nil)
                    (kill-buffer (current-buffer)))
@@ -2507,10 +2507,12 @@ kill-ring."
 (defun notmuch-show-stash-mlarchive-link (&optional mla)
   "Copy an ML Archive URI for the current message to the kill-ring.
 
-This presumes that the message is available at the selected Mailing List Archive.
+This presumes that the message is available at the selected
+Mailing List Archive.
 
-If optional argument MLA is non-nil, use the provided key instead of prompting
-the user (see `notmuch-show-stash-mlarchive-link-alist')."
+If optional argument MLA is non-nil, use the provided key instead
+of prompting the user (see
+`notmuch-show-stash-mlarchive-link-alist')."
   (interactive)
   (let ((url (cdr (assoc
                   (or mla
@@ -2527,12 +2529,15 @@ the user (see `notmuch-show-stash-mlarchive-link-alist')."
        (concat url (notmuch-show-get-message-id t))))))
 
 (defun notmuch-show-stash-mlarchive-link-and-go (&optional mla)
-  "Copy an ML Archive URI for the current message to the kill-ring and visit it.
+  "Copy an ML Archive URI for the current message to the
+ kill-ring and visit it.
 
-This presumes that the message is available at the selected Mailing List Archive.
+This presumes that the message is available at the selected
+Mailing List Archive.
 
-If optional argument MLA is non-nil, use the provided key instead of prompting
-the user (see `notmuch-show-stash-mlarchive-link-alist')."
+If optional argument MLA is non-nil, use the provided key instead
+of prompting the user (see
+`notmuch-show-stash-mlarchive-link-alist')."
   (interactive)
   (notmuch-show-stash-mlarchive-link mla)
   (browse-url (current-kill 0 t)))