From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Andy Moreton Newsgroups: gmane.emacs.bugs Subject: bug#28824: 26.0.90; display of pbm images broken? Date: Sat, 14 Oct 2017 20:03:27 +0100 Message-ID: <86h8v18scg.fsf@gmail.com> References: <29226.45866.855134.23009@gargle.gargle.HOWL> <83376mjjq7.fsf@gnu.org> <86po9p93jz.fsf@gmail.com> <83d15piw5l.fsf@gnu.org> <86lgkd8uj8.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1508007913 31266 195.159.176.226 (14 Oct 2017 19:05:13 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 14 Oct 2017 19:05:13 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.90 (windows-nt) To: 28824@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Oct 14 21:05:07 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e3Rk7-0006wH-ML for geb-bug-gnu-emacs@m.gmane.org; Sat, 14 Oct 2017 21:05:03 +0200 Original-Received: from localhost ([::1]:54967 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e3RkF-0007oI-6Q for geb-bug-gnu-emacs@m.gmane.org; Sat, 14 Oct 2017 15:05:11 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35270) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e3Rk9-0007oD-Ro for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 15:05:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e3Rk6-0007S1-M6 for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 15:05:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:60075) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e3Rk6-0007Rv-It for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 15:05:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1e3Rk6-000124-6C for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 15:05:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <29226.45866.855134.23009@gargle.gargle.HOWL> Resent-From: Andy Moreton Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 14 Oct 2017 19:05:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 28824 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.15080078463894 (code B ref -1); Sat, 14 Oct 2017 19:05:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 14 Oct 2017 19:04:06 +0000 Original-Received: from localhost ([127.0.0.1]:40523 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e3RjB-00010k-U7 for submit@debbugs.gnu.org; Sat, 14 Oct 2017 15:04:06 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:44177) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e3RjA-00010H-Lp for submit@debbugs.gnu.org; Sat, 14 Oct 2017 15:04:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e3Rj4-0006pO-Lh for submit@debbugs.gnu.org; Sat, 14 Oct 2017 15:03:59 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:37870) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1e3Rj4-0006pK-J1 for submit@debbugs.gnu.org; Sat, 14 Oct 2017 15:03:58 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35145) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e3Rj3-0007kG-FQ for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 15:03:58 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e3Rj0-0006nl-CC for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 15:03:57 -0400 Original-Received: from [195.159.176.226] (port=58343 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e3Rj0-0006nL-4c for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 15:03:54 -0400 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1e3Ric-0003zn-JW for bug-gnu-emacs@gnu.org; Sat, 14 Oct 2017 21:03:30 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 43 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:9530hcVOkxKtuW6ktr03M3wCMKQ= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:138414 Archived-At: On Sat 14 Oct 2017, Andy Moreton wrote: > On Sat 14 Oct 2017, Eli Zaretskii wrote: > >>> From: Andy Moreton >>> Date: Sat, 14 Oct 2017 16:01:20 +0100 >>> >>> I see problems with some PBM files from etc/images with emacs 26.0.90 on >>> Windows. The ones that don't work appear to be those that contain a >>> Netpbm header, e.g. back-arrow.pbm close.pbm cut.pbm fwd-arrow.pbm >>> home.pbm >> >> I see no problems with those images you mention as problematic. >> >> Could it be a problem specific to 64-bit builds? > > I've tried this in a 32bit MinGW build with the same results. It appears > to be a problem with the pbm entry in image-type-header-regexps, as > doing (setq image-type-header-regexps '(("\\`P[1-6]" . pbm))) results in > the problematic images displaying correctly. > > AndyM The file format is described at http://netpbm.sourceforge.net/doc/pbm.html Further testing with the images from etc/images in emacs 26 shows that this patch appears to fix the problem: diff --git a/lisp/image.el b/lisp/image.el index 1d0776180b..32df508bc8 100644 --- a/lisp/image.el +++ b/lisp/image.el @@ -34,8 +34,8 @@ 'image-refresh (defconst image-type-header-regexps `(("\\`/[\t\n\r ]*\\*.*XPM.\\*/" . xpm) ("\\`P[1-6]\\(?:\ -\\(?:\\(?:#[^\r\n]*[\r\n]\\)?[[:space:]]\\)+\ -\\(?:\\(?:#[^\r\n]*[\r\n]\\)?[0-9]\\)+\ +\\(?:\\(?:#[^\r\n]*[\r\n]\\)*[[:space:]]\\)+\ +\\(?:\\(?:#[^\r\n]*[\r\n]\\)*[0-9]\\)+\ \\)\\{2\\}" . pbm) ("\\`GIF8[79]a" . gif) ("\\`\x89PNG\r\n\x1a\n" . png)