From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: dick.r.chiang@gmail.com, 49788@debbugs.gnu.org
Subject: bug#49788: 28.0.50; [PATCH] Package archive location needs to be absolute
Date: Sat, 31 Jul 2021 12:32:48 -0400 [thread overview]
Message-ID: <jwv4kcafnz1.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <83o8ajov5k.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 31 Jul 2021 09:27:19 +0300")
>> diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el
>> index f1daa8d124..dfda201af6 100644
>> --- a/lisp/emacs-lisp/package.el
>> +++ b/lisp/emacs-lisp/package.el
>> @@ -1366,10 +1366,10 @@ package--with-response-buffer-1
>> (kill-buffer buffer)
>> (goto-char (point-min))))))
>> (package--unless-error body
>> + (unless (file-name-absolute-p url)
>> + (error "Location %s is not a url nor an absolute file name"
>> + url))
>> (let ((url (expand-file-name file url)))
>> - (unless (file-name-absolute-p url)
>> - (error "Location %s is not a url nor an absolute file name"
>> - url))
>> (insert-file-contents-literally url)))))
>>
>> (define-error 'bad-signature "Failed to verify signature")
>
> Hmm.. if we require it to be an absolute file name, why run it through
> expand-file-name?
>
> Stefan, any comments?
It's not the same `url` we're talking about.
The `file` argument is relative, and the `url` argument should be
absolute.
Stefan
next prev parent reply other threads:[~2021-07-31 16:32 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-31 1:15 bug#49788: 28.0.50; [PATCH] Package archive location needs to be absolute dick.r.chiang
2021-07-31 6:27 ` Eli Zaretskii
2021-07-31 16:32 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2021-08-04 8:50 ` Lars Ingebrigtsen
2021-08-04 12:08 ` Eli Zaretskii
2021-08-04 12:29 ` dick
2021-08-04 12:44 ` Lars Ingebrigtsen
2021-08-04 16:51 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-08-04 17:02 ` Eli Zaretskii
2021-08-04 18:38 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-08-04 19:09 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwv4kcafnz1.fsf-monnier+emacs@gnu.org \
--to=bug-gnu-emacs@gnu.org \
--cc=49788@debbugs.gnu.org \
--cc=dick.r.chiang@gmail.com \
--cc=eliz@gnu.org \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).