summaryrefslogtreecommitdiff
path: root/src/plugins/php/weechat-php.c
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2020-02-28 21:28:29 +0100
committerSébastien Helleu <flashcode@flashtux.org>2020-02-28 21:28:29 +0100
commit91701cbdb41c282ef1adfef8d3e42c41fb083996 (patch)
tree8643d431318363a01928c9168cc23c836a9c109b /src/plugins/php/weechat-php.c
parent3f67cfecc83706f71a740da60936d405ee5dca7a (diff)
downloadweechat-91701cbdb41c282ef1adfef8d3e42c41fb083996.zip
php: fix crash when loading script with PHP 7.4 (closes #1452)
Diffstat (limited to 'src/plugins/php/weechat-php.c')
-rw-r--r--src/plugins/php/weechat-php.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/plugins/php/weechat-php.c b/src/plugins/php/weechat-php.c
index 7ef1b0d21..189c51689 100644
--- a/src/plugins/php/weechat-php.c
+++ b/src/plugins/php/weechat-php.c
@@ -687,11 +687,9 @@ weechat_php_load (const char *filename, const char *code)
php_registered_script = NULL;
php_current_script_filename = filename;
- file_handle.filename = filename;
- file_handle.free_filename = 0;
+ memset (&file_handle, 0, sizeof (file_handle));
file_handle.type = ZEND_HANDLE_FILENAME;
- file_handle.opened_path = NULL;
- file_handle.handle.fp = NULL;
+ file_handle.filename = filename;
zend_try
{