From 32b8f345673f5eb736a27090e98de808f6e7fda2 Mon Sep 17 00:00:00 2001 From: Sebastien Helleu Date: Mon, 23 Jul 2012 19:10:27 +0200 Subject: [PATCH] irc: replace calls to config_search_with_string with weechat_config_get --- src/plugins/irc/irc-protocol.c | 12 ++++-------- src/plugins/irc/irc-server.c | 6 ++---- 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/src/plugins/irc/irc-protocol.c b/src/plugins/irc/irc-protocol.c index 4fe9e4965..e7c4d7f77 100644 --- a/src/plugins/irc/irc-protocol.c +++ b/src/plugins/irc/irc-protocol.c @@ -3830,10 +3830,8 @@ IRC_PROTOCOL_CALLBACK(366) if (strcmp (weechat_infolist_string (infolist, "type"), "nick") == 0) { - weechat_config_search_with_string (weechat_infolist_string (infolist, - "prefix_color"), - NULL, NULL, &ptr_option, - NULL); + ptr_option = weechat_config_get (weechat_infolist_string (infolist, + "prefix_color")); length += ((ptr_option) ? strlen (weechat_color (weechat_config_string (ptr_option))) : 0) + strlen (weechat_infolist_string (infolist, "prefix")) + @@ -3867,10 +3865,8 @@ IRC_PROTOCOL_CALLBACK(366) "prefix_color"); if (strchr (prefix_color, '.')) { - weechat_config_search_with_string (weechat_infolist_string (infolist, - "prefix_color"), - NULL, NULL, &ptr_option, - NULL); + ptr_option = weechat_config_get (weechat_infolist_string (infolist, + "prefix_color")); if (ptr_option) strcat (string, weechat_color (weechat_config_string (ptr_option))); } diff --git a/src/plugins/irc/irc-server.c b/src/plugins/irc/irc-server.c index 1aefc0056..6d14fd18a 100644 --- a/src/plugins/irc/irc-server.c +++ b/src/plugins/irc/irc-server.c @@ -1417,10 +1417,8 @@ irc_server_rename (struct t_irc_server *server, const char *new_server_name) { while (weechat_infolist_next (infolist)) { - weechat_config_search_with_string (weechat_infolist_string (infolist, - "full_name"), - NULL, NULL, &ptr_option, - NULL); + ptr_option = weechat_config_get (weechat_infolist_string (infolist, + "full_name")); if (ptr_option) { option_name = weechat_infolist_string (infolist, "option_name");