summaryrefslogtreecommitdiff
path: root/src/plugins/php/weechat-php-api.c
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2022-08-01 22:18:38 +0200
committerSébastien Helleu <flashcode@flashtux.org>2022-08-01 22:18:38 +0200
commitbcb8647aa47ae2213bedbdd3506d5af3a7c60c10 (patch)
treef21ee78d4c8c344c3d4155b3e31e1bca1d5d8bf2 /src/plugins/php/weechat-php-api.c
parentb1404b02777c58d5e104082f349dff201bd12ef8 (diff)
downloadweechat-bcb8647aa47ae2213bedbdd3506d5af3a7c60c10.zip
scripts: fix issue with long interval in function hook_timer
Affected plugins: python, ruby, lua, tcl, guile, javascript, php.
Diffstat (limited to 'src/plugins/php/weechat-php-api.c')
-rw-r--r--src/plugins/php/weechat-php-api.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/php/weechat-php-api.c b/src/plugins/php/weechat-php-api.c
index cfe2ffaca..b28561040 100644
--- a/src/plugins/php/weechat-php-api.c
+++ b/src/plugins/php/weechat-php-api.c
@@ -2376,7 +2376,8 @@ API_FUNC(hook_timer)
zend_long z_interval, z_align_second, z_max_calls;
zval *z_callback;
zend_string *z_data;
- int interval, align_second, max_calls;
+ long interval;
+ int align_second, max_calls;
char *data;
const char *result;
@@ -2386,7 +2387,7 @@ API_FUNC(hook_timer)
&z_data) == FAILURE)
API_WRONG_ARGS(API_RETURN_EMPTY);
- interval = (int)z_interval;
+ interval = (long)z_interval;
align_second = (int)z_align_second;
max_calls = (int)z_max_calls;
weechat_php_get_function_name (z_callback, callback_name);