Bug 272939 - devel/pear-htmlpurifier: support for php81 "Generates a PHP fatal error: Array and string offset access syntax with curly braces is no longer supported"
Summary: devel/pear-htmlpurifier: support for php81 "Generates a PHP fatal error: Arra...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Vladimir Druzenko
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-08-04 15:12 UTC by Joel Rodriguez
Modified: 2023-08-04 18:04 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joel Rodriguez 2023-08-04 15:12:05 UTC
Generates a PHP fatal error: Array and string offset access syntax with curly braces is no longer supported

code:

           $in = ord($str{$i});

suggested fix:

           $in = ord($str[$i]);
Comment 1 commit-hook freebsd_committer freebsd_triage 2023-08-04 17:58:48 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=94ea65b1037c4e04fb2d2a6e0ee1480f0b254179

commit 94ea65b1037c4e04fb2d2a6e0ee1480f0b254179
Author:     Vladimir Druzenko <vvd@FreeBSD.org>
AuthorDate: 2023-08-04 17:53:44 +0000
Commit:     Vladimir Druzenko <vvd@FreeBSD.org>
CommitDate: 2023-08-04 17:53:44 +0000

    devel/pear-htmlpurifier: update to 4.15.0 for support PHP 8+

    Runtime errors with PHP 8.1:
    "Generates a PHP fatal error: autoload() is no longer supported, use
    spl_autoload_register()"
    "Generates a PHP fatal error: Array and string offset access syntax with
    curly braces is no longer supported"

    Changelog: https://github.com/ezyang/htmlpurifier/blob/master/NEWS
    4.15.0, released 2022-09-18
    ! PHP 8.1 and 8.2 support, esp. fixes for deprecation warnings.

    PR:                     272938 272939
    Approved by:            adamw (mentor)
    Differential Revision:  https://reviews.freebsd.org/D41323
    MFH:                    2023Q3

 devel/pear-htmlpurifier/Makefile | 3 +--
 devel/pear-htmlpurifier/distinfo | 6 +++---
 2 files changed, 4 insertions(+), 5 deletions(-)
Comment 2 commit-hook freebsd_committer freebsd_triage 2023-08-04 18:03:51 UTC
A commit in branch 2023Q3 references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=c0e935c195d85458402cd70a1fc8708dc8227aab

commit c0e935c195d85458402cd70a1fc8708dc8227aab
Author:     Vladimir Druzenko <vvd@FreeBSD.org>
AuthorDate: 2023-08-04 17:53:44 +0000
Commit:     Vladimir Druzenko <vvd@FreeBSD.org>
CommitDate: 2023-08-04 18:02:56 +0000

    devel/pear-htmlpurifier: update to 4.15.0 for support PHP 8+

    Runtime errors with PHP 8.1:
    "Generates a PHP fatal error: autoload() is no longer supported, use
    spl_autoload_register()"
    "Generates a PHP fatal error: Array and string offset access syntax with
    curly braces is no longer supported"

    Changelog: https://github.com/ezyang/htmlpurifier/blob/master/NEWS
    4.15.0, released 2022-09-18
    ! PHP 8.1 and 8.2 support, esp. fixes for deprecation warnings.

    PR:                     272938 272939
    Approved by:            adamw (mentor)
    Differential Revision:  https://reviews.freebsd.org/D41323
    MFH:                    2023Q3

    (cherry picked from commit 94ea65b1037c4e04fb2d2a6e0ee1480f0b254179)

 devel/pear-htmlpurifier/Makefile | 3 +--
 devel/pear-htmlpurifier/distinfo | 6 +++---
 2 files changed, 4 insertions(+), 5 deletions(-)
Comment 3 Vladimir Druzenko freebsd_committer freebsd_triage 2023-08-04 18:04:51 UTC
Commited new version.