mirror of
https://github.com/weechat/weechat.git
synced 2026-06-27 05:16:38 +02:00
Remove debug plugin (merged to core), new debug variable for each plugin (no more signals for setting debug)
This commit is contained in:
@@ -138,6 +138,7 @@ plugin_load (const char *filename)
|
||||
int rc, i, argc;
|
||||
char **argv;
|
||||
struct t_weechat_plugin *new_plugin;
|
||||
struct t_config_option *ptr_option;
|
||||
|
||||
if (!filename)
|
||||
return NULL;
|
||||
@@ -316,6 +317,8 @@ plugin_load (const char *filename)
|
||||
new_plugin->weechat_version = strdup (weechat_version);
|
||||
new_plugin->license = strdup (license);
|
||||
new_plugin->charset = (charset) ? strdup (charset) : NULL;
|
||||
ptr_option = config_weechat_debug_get (name);
|
||||
new_plugin->debug = (ptr_option) ? CONFIG_INTEGER(ptr_option) : 0;
|
||||
|
||||
/* functions */
|
||||
new_plugin->plugin_get_name = &plugin_get_name;
|
||||
@@ -923,6 +926,8 @@ plugin_add_to_infolist (struct t_infolist *infolist,
|
||||
return 0;
|
||||
if (!infolist_new_var_string (ptr_item, "charset", plugin->charset))
|
||||
return 0;
|
||||
if (!infolist_new_var_integer (ptr_item, "debug", plugin->debug))
|
||||
return 0;
|
||||
|
||||
return 1;
|
||||
}
|
||||
@@ -947,6 +952,7 @@ plugin_print_log ()
|
||||
log_printf (" description. . . . . . : '%s'", ptr_plugin->description);
|
||||
log_printf (" version. . . . . . . . : '%s'", ptr_plugin->version);
|
||||
log_printf (" charset. . . . . . . . : '%s'", ptr_plugin->charset);
|
||||
log_printf (" debug. . . . . . . . . : %d", ptr_plugin->debug);
|
||||
log_printf (" prev_plugin. . . . . . : 0x%x", ptr_plugin->prev_plugin);
|
||||
log_printf (" next_plugin. . . . . . : 0x%x", ptr_plugin->next_plugin);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user