From 65cdc2603a0bd6ca75e6e1244a067564d932d294 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Sun, 25 Feb 2024 16:12:54 +0100 Subject: [PATCH] tcl: fix truncation of long integer returned by function hdata_long --- ChangeLog.adoc | 1 + src/plugins/tcl/weechat-tcl-api.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/ChangeLog.adoc b/ChangeLog.adoc index 9833ccd8b..82ac8ecd8 100644 --- a/ChangeLog.adoc +++ b/ChangeLog.adoc @@ -17,6 +17,7 @@ Bug fixes:: * core: add missing mouse events "alt-ctrl-button2" and "alt-ctrl-button3" * script: always display list of scripts when searching scripts with `/script search` (issue #2077) + * tcl: fix truncation of long integer returned by function hdata_long * trigger: fix memory leak when adding a new trigger with `/trigger` command Build:: diff --git a/src/plugins/tcl/weechat-tcl-api.c b/src/plugins/tcl/weechat-tcl-api.c index 7be25196a..4a19c4cb7 100644 --- a/src/plugins/tcl/weechat-tcl-api.c +++ b/src/plugins/tcl/weechat-tcl-api.c @@ -5510,7 +5510,8 @@ API_FUNC(hdata_long) { Tcl_Obj *objp; char *hdata, *pointer, *name; - int result, i; + long result; + int i; API_INIT_FUNC(1, "hdata_long", API_RETURN_LONG(0)); if (objc < 4)