summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorAdam Saponara <as@php.net>2021-08-08 08:55:40 +0200
committerSébastien Helleu <flashcode@flashtux.org>2021-08-08 09:00:24 +0200
commitede09a843ca5999efd077c22007585b9e8be466a (patch)
tree3a5ba26963948c48dadd8b9ce464e9dad2883e54 /src/plugins
parent5442612bc987cdaa49f5b540582cbe6129018c7b (diff)
downloadweechat-ede09a843ca5999efd077c22007585b9e8be466a.zip
php: add ifdef for zend_file_handle.filename
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/php/weechat-php.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/plugins/php/weechat-php.c b/src/plugins/php/weechat-php.c
index d303367a6..942bac425 100644
--- a/src/plugins/php/weechat-php.c
+++ b/src/plugins/php/weechat-php.c
@@ -700,7 +700,11 @@ weechat_php_load (const char *filename, const char *code)
memset (&file_handle, 0, sizeof (file_handle));
file_handle.type = ZEND_HANDLE_FILENAME;
+#if PHP_VERSION_ID >= 80100
file_handle.filename = zend_string_init(filename, strlen(filename), 0);
+#else
+ file_handle.filename = filename;
+#endif
zend_try
{