From 34f2e6cdd0e21175b89cc29369d1bdc32269808a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Sun, 8 Jun 2025 16:36:46 +0200 Subject: [PATCH] core: add script name in output of `/debug hooks ` --- CHANGELOG.md | 1 + src/core/core-debug.c | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 084a56381..2ee619ef0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ SPDX-License-Identifier: GPL-3.0-or-later - **breaking:** core: fix buffer overflow in function utf8_next_char and return NULL for empty string - **breaking:** core: fix integer overflow and return "unsigned long" in function util_version_number - core: write configuration files on disk only if there are changes ([#2250](https://github.com/weechat/weechat/issues/2250)) +- core: add script name in output of `/debug hooks ` ### Added diff --git a/src/core/core-debug.c b/src/core/core-debug.c index bd8a517fd..365a89d72 100644 --- a/src/core/core-debug.c +++ b/src/core/core-debug.c @@ -611,6 +611,12 @@ debug_hooks_plugin_types (const char *plugin_mask, const char **hook_types) (ptr_hook->plugin) ? ptr_hook->plugin->name : PLUGIN_CORE, -1); + if (ptr_hook->subplugin) + { + string_dyn_concat (result_type, "(", -1); + string_dyn_concat (result_type, ptr_hook->subplugin, -1); + string_dyn_concat (result_type, ")", -1); + } string_dyn_concat (result_type, ": ", -1); string_dyn_concat (result_type, desc, -1); string_dyn_concat (result_type, "\n", -1);