summaryrefslogtreecommitdiffstats
path: root/9.patch
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2022-09-15 09:08:40 +0200
committerRemi Collet <remi@php.net>2022-09-15 09:08:40 +0200
commitc61b96d3f9c3f7ce58dd6112204d5cf4c757f4e5 (patch)
tree913b43bd203b04dad71a41fc923492257be3efdb /9.patch
parentfac6c2df737b05c076fe566003b37de9eb14de0a (diff)
add patch for PHP 8.2 from
https://github.com/SeasX/SeasSnowflake/pull/9
Diffstat (limited to '9.patch')
-rw-r--r--9.patch22
1 files changed, 22 insertions, 0 deletions
diff --git a/9.patch b/9.patch
new file mode 100644
index 0000000..c37a501
--- /dev/null
+++ b/9.patch
@@ -0,0 +1,22 @@
+From b164b83c6a25a820df4ada579dbd80c962a85b24 Mon Sep 17 00:00:00 2001
+From: Remi Collet <remi@remirepo.net>
+Date: Thu, 15 Sep 2022 09:02:36 +0200
+Subject: [PATCH] declare class properties
+
+---
+ SeasSnowflake.cpp | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/SeasSnowflake.cpp b/SeasSnowflake.cpp
+index 7c5fee0..12c0d99 100644
+--- a/SeasSnowflake.cpp
++++ b/SeasSnowflake.cpp
+@@ -94,6 +94,8 @@ PHP_MINIT_FUNCTION(SeasSnowflake)
+ INIT_CLASS_ENTRY(SeasSnowflake, SEASSNOWFLAKE_RES_NAME, SeasSnowflake_methods);
+ #if PHP_VERSION_ID >= 70000
+ SeasSnowflake_ce = zend_register_internal_class_ex(&SeasSnowflake, NULL);
++ zend_declare_property_null(SeasSnowflake_ce, "worker_id", sizeof("worker_id")-1, ZEND_ACC_PUBLIC);
++ zend_declare_property_null(SeasSnowflake_ce, "datacenter_id", sizeof("datacenter_id")-1, ZEND_ACC_PUBLIC);
+ #else
+ SeasSnowflake_ce = zend_register_internal_class_ex(&SeasSnowflake, NULL, NULL TSRMLS_CC);
+ #endif