From patchwork Tue Feb 4 05:06:09 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Eric Bavier X-Patchwork-Id: 20074 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 9E689168C9; Tue, 4 Feb 2020 05:05:12 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id 5C4A6168C3 for ; Tue, 4 Feb 2020 05:05:12 +0000 (GMT) Received: from localhost ([::1]:52896 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iyqOd-0001mq-Mx for patchwork@mira.cbaines.net; Tue, 04 Feb 2020 00:05:11 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:41599) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iyqOX-0001lv-8e for guix-patches@gnu.org; Tue, 04 Feb 2020 00:05:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iyqOW-0002TW-0h for guix-patches@gnu.org; Tue, 04 Feb 2020 00:05:05 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:36556) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iyqOU-0002Rq-GM for guix-patches@gnu.org; Tue, 04 Feb 2020 00:05:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iyqOU-0006DW-BD for guix-patches@gnu.org; Tue, 04 Feb 2020 00:05:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#39410] [PATCH] gnu: netsurf: Fix entity parsing. Resent-From: Eric Bavier Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 04 Feb 2020 05:05:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 39410 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 39410@debbugs.gnu.org Cc: Eric Bavier X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.158079266723843 (code B ref -1); Tue, 04 Feb 2020 05:05:02 +0000 Received: (at submit) by debbugs.gnu.org; 4 Feb 2020 05:04:27 +0000 Received: from localhost ([127.0.0.1]:42529 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iyqNq-0006CP-Cl for submit@debbugs.gnu.org; Tue, 04 Feb 2020 00:04:27 -0500 Received: from lists.gnu.org ([209.51.188.17]:42232) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iyqNo-0006CG-E2 for submit@debbugs.gnu.org; Tue, 04 Feb 2020 00:04:20 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:40781) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iyqNn-0001O8-83 for guix-patches@gnu.org; Tue, 04 Feb 2020 00:04:20 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iyqNm-00032a-1u for guix-patches@gnu.org; Tue, 04 Feb 2020 00:04:19 -0500 Received: from mout01.posteo.de ([185.67.36.141]:43473) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1iyqNl-0002mm-QS for guix-patches@gnu.org; Tue, 04 Feb 2020 00:04:17 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id D393A160060 for ; Tue, 4 Feb 2020 06:04:15 +0100 (CET) Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 48BXfk3jjCz6tm7; Tue, 4 Feb 2020 06:04:14 +0100 (CET) From: Eric Bavier Date: Mon, 3 Feb 2020 23:06:09 -0600 Message-Id: <20200204050609.27557-1-bavier@member.fsf.org> X-Mailer: git-send-email 2.25.0 MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] 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: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches From: Eric Bavier From: Eric Bavier Follow-up to commit 31afa654c58cd7aa8bd11a771fa6eabcd766d443. * gnu/packages/web.scm (netsurf)[arguments]: In 'adjust-welcome' phase, ensure html entities are parsed and find their way back to the output. --- gnu/packages/web.scm | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index f6ae958ae3..60fd5cfd0f 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Ricardo Wurmus ;;; Copyright © 2018 Raoul Jean Pierre Bonnal ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer -;;; Copyright © 2015, 2016, 2017, 2018, 2019 Eric Bavier +;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Eric Bavier ;;; Copyright © 2015 Eric Dvorsak ;;; Copyright © 2016 Sou Bunnbu ;;; Copyright © 2016 Jelle Licht @@ -5075,12 +5075,19 @@ w3c webidl files and a binding configuration file.") ;; Leave the DOCTYPE header as is. (display (read-line in 'concat) out) (sxml->xml - (let rec ((sxml (xml->sxml in))) + (let rec ((sxml (xml->sxml in + #:default-entity-handler + (lambda (port name) + (string-append "" + (symbol->string name) + ""))))) ;; We'd like to use sxml-match here, but it can't ;; match against generic tag symbols... (match sxml (`(div (@ (class "links")) . ,rest) '()) + (`(ENTITY ,ent) + `(*ENTITY* ,ent)) ((x ...) (map rec x)) (x x)))