From: Visuwesh <visuweshm@gmail.com>
To: john muhl <jm@pub.pink>
Cc: 67764@debbugs.gnu.org
Subject: bug#67764: 30.0.50; Opening image in eww no longer works
Date: Mon, 11 Dec 2023 17:10:01 +0530 [thread overview]
Message-ID: <87sf49ge7i.fsf@gmail.com> (raw)
In-Reply-To: <87msuhfdjr.fsf@pub.pink> (john muhl via's message of "Mon, 11 Dec 2023 00:26:41 -0600")
[-- Attachment #1: Type: text/plain, Size: 483 bytes --]
[Monday December 11, 2023] john muhl via "Bug reports for GNU Emacs, the Swiss army knife of text editors" wrote:
> In Emacs 29.1 the image opens as expected:
>
> emacs -Q
> M-: (eww "https://www.gnu.org/software/emacs/images/emacs.png")
>
> On master it fails with "Wrong type argument: stringp, nil".
> Bisect says 4254544 is the first bad commit.
Recent changes in shr-put-image didn't account for the possible nil
value for ALT. Attached patch fixes the issue on my end.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Fix-shr-put-image-with-nil-value-for-ALT.patch --]
[-- Type: text/x-diff, Size: 885 bytes --]
From f6d3fc0de572a1039e83df0389c1c7efce0ef0cf Mon Sep 17 00:00:00 2001
From: Visuwesh <visuweshm@gmail.com>
Date: Mon, 11 Dec 2023 17:09:03 +0530
Subject: [PATCH] ; Fix shr-put-image with nil value for ALT
* lisp/net/shr.el (shr-put-image): Account for nil value for ALT.
(Bug#6774)
---
lisp/net/shr.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lisp/net/shr.el b/lisp/net/shr.el
index 9f030b4c743..19c52ac8802 100644
--- a/lisp/net/shr.el
+++ b/lisp/net/shr.el
@@ -1137,7 +1137,7 @@ shr-put-image
(when image
;; The trailing space can confuse shr-insert into not
;; putting any space after inline images.
- (setq alt (string-trim alt))
+ (setq alt (string-trim (or alt "*")))
;; When inserting big-ish pictures, put them at the
;; beginning of the line.
(let ((inline (shr--inline-image-p image)))
--
2.42.0
next prev parent reply other threads:[~2023-12-11 11:40 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-11 6:26 bug#67764: 30.0.50; Opening image in eww no longer works john muhl via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-12-11 11:40 ` Visuwesh [this message]
2023-12-11 15:03 ` john muhl via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-12-11 15:47 ` Eli Zaretskii
2023-12-12 4:12 ` Visuwesh
2023-12-12 8:14 ` Manuel Giraud via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-12-12 9:14 ` Visuwesh
2023-12-16 12:53 ` 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=87sf49ge7i.fsf@gmail.com \
--to=visuweshm@gmail.com \
--cc=67764@debbugs.gnu.org \
--cc=jm@pub.pink \
/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).