From nobody Mon Sep 18 12:41:04 2023 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Rq4Cj11CFz4t7w0; Mon, 18 Sep 2023 12:41:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rq4Cj0bqxz4LMp; Mon, 18 Sep 2023 12:41:05 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1695040865; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=7lc5uVO7CS/u2oDcScyIu6xw6hPmKW1wFz3kLnw5mHM=; b=PUwEFCXYTnmfFktZUe+5i5jNKz4JhWhxLdJJwCSarkJSuGr66tdtOKAtf7mlqexWOgXee5 Xb8mxqcMqFB1YavbhfW7veCYYY8i/F08C51GbM1boMtl7Kk7YuIy7MCaNjXM0Th24gaHRf hXurgU0Q81zBs1tHA607qp+IxHvFbLgfYXLOLv8KJ6pKAecmQ6+Ztgvm3VxUNoj5vvy9lb J+O1KsqMQkB+I7jXAmEFLZDBkqANiBcUkvpfTgaw8/a2OP9SXP0y+35sc3J/wHWfRWdWRj hwgcfTTgbNIgBK7086xqjFaeKlKsTuivGUmkL0WvdWeH6zZFhkY7k0bsiQyYiQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1695040865; a=rsa-sha256; cv=none; b=VP5wVGygax/rKHQt6nwnmjpdwtioHW88VYeX/20XCOMxKOvuhOqLpkwLdnYxr1I+DpJI/3 A8XRdGqF5Fm2gL3LwaWnUrzlYQtBEU/3zfvve6bRZT7xEpV98xzO/VIc2mTb8pqiyUnWjf H7GhlAIKX7XIPkB6vUxxcctH47ZW7gqeOZNQf0bm9yMGqbtrEHgYJKQ8+J5Q7IusZEKWFm sIqQhtiBkqHRPiaMveOlZtTxhD8LmR5AlsVT6bf+1gbOWguAy3Zz9QIuOLpfAwEdoGCSIa Ci1mm4euRvXXhcs1Hv1PX11QnatUXadK8zX9dHfEFDOeCGl4LuEtca23ZjC5mg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1695040865; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=7lc5uVO7CS/u2oDcScyIu6xw6hPmKW1wFz3kLnw5mHM=; b=W2deytDTOmDRs8KcWLK+VkGgVhLXwM7qM8FGPrWjG1SfgtWA3DViakfGY8rI04amcS7fwE BdCYQumgOUX+YYMPvSw5hIUy3M9z7OsqnqCd8LN1G5OL0lk68oAmuTW5+TVKFalc2tgFBg xXcchszFzXBQaM6RjKQ3q9EdaBwf8ZZAQltIdSXTz6qkjJOZt6hmqiiM+ZSGs8OIw8oHWl FosWa0rzu/w16gSuD5JNfBxHpZP3XwZqAJifF+kgxQuBiLc99x0yd5/O8eJz0EjDv+hVlT exkS+ZUo9sWZgR2WIWxhO2Hs8Lb28DSlr5MI1KIIrzYZver2eP2U8BGhIdTXOw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Rq4Ch6p3wzWrw; Mon, 18 Sep 2023 12:41:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 38ICf4lf023606; Mon, 18 Sep 2023 12:41:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 38ICf447023589; Mon, 18 Sep 2023 12:41:04 GMT (envelope-from git) Date: Mon, 18 Sep 2023 12:41:04 GMT Message-Id: <202309181241.38ICf447023589@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Vladimir Druzenko Subject: git: 3f1b38acfda1 - main - www/phpvirtualbox{,-legacy}: PHP 8 support (1 more catch) - "preg_replace" List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: vvd X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3f1b38acfda124fc8f03fe5f4edfef10ef214501 Auto-Submitted: auto-generated The branch main has been updated by vvd: URL: https://cgit.FreeBSD.org/ports/commit/?id=3f1b38acfda124fc8f03fe5f4edfef10ef214501 commit 3f1b38acfda124fc8f03fe5f4edfef10ef214501 Author: Vladimir Druzenko AuthorDate: 2023-09-18 12:35:49 +0000 Commit: Vladimir Druzenko CommitDate: 2023-09-18 12:39:54 +0000 www/phpvirtualbox{,-legacy}: PHP 8 support (1 more catch) - "preg_replace" Fixed: PHP Warning: preg_replace() expects at least 3 parameters, 2 given in endpoints/screen.php on line 91 PR: 261498 Approved by: tcberner (mentor) MFH: 2023Q3 --- www/phpvirtualbox-legacy/Makefile | 2 +- www/phpvirtualbox/Makefile | 2 +- www/phpvirtualbox/files/patch-php8 | 28 +++++++++++++++++++++++++--- 3 files changed, 27 insertions(+), 5 deletions(-) diff --git a/www/phpvirtualbox-legacy/Makefile b/www/phpvirtualbox-legacy/Makefile index 38709462e376..ba80ba721ec8 100644 --- a/www/phpvirtualbox-legacy/Makefile +++ b/www/phpvirtualbox-legacy/Makefile @@ -1,6 +1,6 @@ PORTNAME= phpvirtualbox DISTVERSION= 5.2-1 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= www PKGNAMESUFFIX= -legacy diff --git a/www/phpvirtualbox/Makefile b/www/phpvirtualbox/Makefile index 4c4929542c6f..cc67954d33a0 100644 --- a/www/phpvirtualbox/Makefile +++ b/www/phpvirtualbox/Makefile @@ -1,6 +1,6 @@ PORTNAME= phpvirtualbox DISTVERSION= 6.1 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= www MAINTAINER= vbox@FreeBSD.org diff --git a/www/phpvirtualbox/files/patch-php8 b/www/phpvirtualbox/files/patch-php8 index d6566684b8ca..477a1596ba4c 100644 --- a/www/phpvirtualbox/files/patch-php8 +++ b/www/phpvirtualbox/files/patch-php8 @@ -144,12 +144,34 @@ diff -ur endpoints/screen.php.orig endpoints/screen.php // Let the browser cache images for 3 seconds $ctime = 0; - if(strpos($_SERVER['HTTP_IF_NONE_MATCH'],'_')) { -+ if(strpos($_SERVER['HTTP_IF_NONE_MATCH'] ?? '','_')) { - $ctime = preg_replace("/.*_/",str_replace('"','',$_SERVER['HTTP_IF_NONE_MATCH'])); +- $ctime = preg_replace("/.*_/",str_replace('"','',$_SERVER['HTTP_IF_NONE_MATCH'])); - } else if(strpos($_ENV['HTTP_IF_NONE_MATCH'],'_')) { +- $ctime = preg_replace("/.*_/",str_replace('"','',$_ENV['HTTP_IF_NONE_MATCH'])); +- } else if(strpos($_SERVER['HTTP_IF_MODIFIED_SINCE'],'GMT')) { ++ if(strpos($_SERVER['HTTP_IF_NONE_MATCH'] ?? '','_')) { ++ $ctime = preg_replace("/.*_/","",str_replace('"','',$_SERVER['HTTP_IF_NONE_MATCH'])); + } else if(strpos($_ENV['HTTP_IF_NONE_MATCH'] ?? '','_')) { - $ctime = preg_replace("/.*_/",str_replace('"','',$_ENV['HTTP_IF_NONE_MATCH'])); ++ $ctime = preg_replace("/.*_/","",str_replace('"','',$_ENV['HTTP_IF_NONE_MATCH'])); ++ } else if(strpos($_SERVER['HTTP_IF_MODIFIED_SINCE'] ?? '','GMT')) { + $ctime = strtotime($_SERVER['HTTP_IF_MODIFIED_SINCE']); +- } else if(strpos($_ENV['HTTP_IF_MODIFIED_SINCE'],'GMT')) { ++ } else if(strpos($_ENV['HTTP_IF_MODIFIED_SINCE'] ?? '','GMT')) { + $ctime = strtotime($_ENV['HTTP_IF_MODIFIED_SINCE']); + } + +@@ -164,13 +164,13 @@ + + // Let the browser cache saved state images + $ctime = 0; +- if(strpos($_SERVER['HTTP_IF_NONE_MATCH'],'_')) { +- $ctime = preg_replace("/.*_/",str_replace('"','',$_SERVER['HTTP_IF_NONE_MATCH'])); +- } else if(strpos($_ENV['HTTP_IF_NONE_MATCH'],'_')) { +- $ctime = preg_replace("/.*_/",str_replace('"','',$_ENV['HTTP_IF_NONE_MATCH'])); - } else if(strpos($_SERVER['HTTP_IF_MODIFIED_SINCE'],'GMT')) { ++ if(strpos($_SERVER['HTTP_IF_NONE_MATCH'] ?? '','_')) { ++ $ctime = preg_replace("/.*_/","",str_replace('"','',$_SERVER['HTTP_IF_NONE_MATCH'])); ++ } else if(strpos($_ENV['HTTP_IF_NONE_MATCH'] ?? '','_')) { ++ $ctime = preg_replace("/.*_/","",str_replace('"','',$_ENV['HTTP_IF_NONE_MATCH'])); + } else if(strpos($_SERVER['HTTP_IF_MODIFIED_SINCE'] ?? '','GMT')) { $ctime = strtotime($_SERVER['HTTP_IF_MODIFIED_SINCE']); - } else if(strpos($_ENV['HTTP_IF_MODIFIED_SINCE'],'GMT')) {