diff options
-rw-r--r-- | 170.patch | 23 | ||||
-rw-r--r-- | composer.json | 2 | ||||
-rw-r--r-- | php-masterminds-html5.spec | 17 |
3 files changed, 37 insertions, 5 deletions
diff --git a/170.patch b/170.patch new file mode 100644 index 0000000..076b8d4 --- /dev/null +++ b/170.patch @@ -0,0 +1,23 @@ +From 70d36f21e9223cad511dbc149c299b1143d264e4 Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Fri, 11 Oct 2019 10:30:57 +0200 +Subject: [PATCH] Fix Trying to access array offset on value of type null + +--- + test/HTML5/Parser/TokenizerTest.php | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/test/HTML5/Parser/TokenizerTest.php b/test/HTML5/Parser/TokenizerTest.php +index 153dd23..6c90686 100644 +--- a/test/HTML5/Parser/TokenizerTest.php ++++ b/test/HTML5/Parser/TokenizerTest.php +@@ -26,7 +26,8 @@ public function assertEventEquals($type, $expects, $event) + if (is_array($expects)) { + $this->assertEquals($expects, $event['data'], "Event $type should equal " . print_r($expects, true) . ': ' . print_r($event, true)); + } else { +- $this->assertEquals($expects, $event['data'][0], "Event $type should equal $expects: " . print_r($event, true)); ++ $d = (is_array($event['data']) ? $event['data'][0] : null); ++ $this->assertEquals($expects, $d, "Event $type should equal $expects: " . print_r($event, true)); + } + } + diff --git a/composer.json b/composer.json index a1c059b..6504790 100644 --- a/composer.json +++ b/composer.json @@ -38,7 +38,7 @@ }, "extra": { "branch-alias": { - "dev-master": "2.6-dev" + "dev-master": "2.7-dev" } } } diff --git a/php-masterminds-html5.spec b/php-masterminds-html5.spec index c143fc3..6a011d5 100644 --- a/php-masterminds-html5.spec +++ b/php-masterminds-html5.spec @@ -12,8 +12,8 @@ %global github_owner Masterminds %global github_name html5-php -%global github_version 2.6.0 -%global github_commit c961ca6a0a81dc6b55b6859b3f9ea7f402edf9ad +%global github_version 2.7.0 +%global github_commit 104443ad663d15981225f99532ba73c2f1d6b6f2 %global composer_vendor masterminds %global composer_project html5 @@ -35,6 +35,8 @@ License: MIT URL: http://masterminds.github.io/html5-php Source0: https://github.com/%{github_owner}/%{github_name}/archive/%{github_commit}/%{name}-%{github_version}-%{github_commit}.tar.gz +Patch0: https://patch-diff.githubusercontent.com/raw/Masterminds/html5-php/pull/170.patch + BuildArch: noarch # Autoload generation BuildRequires: %{_bindir}/phpab @@ -45,7 +47,7 @@ BuildRequires: php(language) >= %{php_min_ver} BuildRequires: php-composer(phpunit/phpunit) >= 4.8.35 BuildRequires: php-ctype BuildRequires: php-dom -## phpcompatinfo (computed from version 2.6.0) +## phpcompatinfo (computed from version 2.7.0) BuildRequires: php-iconv BuildRequires: php-json BuildRequires: php-mbstring @@ -56,13 +58,14 @@ BuildRequires: php-spl # composer.json Requires: php(language) >= %{php_min_ver} -# phpcompatinfo (computed from version 2.6.0) Requires: php-ctype Requires: php-dom +# phpcompatinfo (computed from version 2.7.0) Requires: php-iconv Requires: php-mbstring Requires: php-pcre Requires: php-spl +# notice: xml only detected for utf8_decode # Composer Provides: php-composer(%{composer_vendor}/%{composer_project}) = %{version} @@ -82,6 +85,7 @@ refactoring work, we began a new parser. %prep %setup -qn %{github_name}-%{github_commit} +%patch0 -p1 -b .pr170 : Docs mkdir -p docs/{Parser,Serializer} @@ -139,6 +143,11 @@ exit $RETURN_CODE %changelog +* Fri Oct 11 2019 Remi Collet <remi@remirepo.net> - 2.7.0-1 +- update to 2.7.0 +- add patch for PHP 7.4 from + https://github.com/Masterminds/html5-php/pull/170 + * Sat May 25 2019 Shawn Iwinski <shawn.iwinski@gmail.com> - 2.6.0-1 - Update to 2.6.0 (RHBZ #1687215) |