GNU bug report logs -
#74879
30.0.92; trusted-content-p and trusted-files cannot be used for non-file buffers
Previous Next
Full log
View this message in rfc822 format
Hello Stefan,
I just took another look at the `trusted-content-p' function on the
emacs-30 branch:
(defun trusted-content-p ()
(and (not untrusted-content)
buffer-file-truename
...))
There is a check for `buffer-file-truename' which means that the issue
with non-file-backed buffers remains (Ielm or scratch). Probably (eq
trusted-content :all) should be checked first?
(defun trusted-content-p ()
(and (not untrusted-content)
(or (eq trusted-content :all)
(and buffer-file-name
...))))
At the same time one could consolidate the untrusted-content and
trusted-content variables as Eshel suggested?
(defun trusted-content-p ()
(and (not untrusted-content) ;; only for backward compat (deprecated)
(not (eq trusted-content :untrusted)) ;; replaces untrusted-content
(or (eq trusted-content :all)
(and buffer-file-name
...))))
Daniel
This bug report was last modified 55 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.