irc: return "count" in hashtable built by irc_server_sendf
This commit is contained in:
parent
832a089d3d
commit
5e6e3de553
@ -1749,7 +1749,7 @@ struct t_hashtable *
|
||||
irc_server_sendf (struct t_irc_server *server, int flags, const char *tags,
|
||||
const char *format, ...)
|
||||
{
|
||||
char **items, hash_key[32];
|
||||
char **items, hash_key[32], value[32];
|
||||
const char *str_message, *str_args;
|
||||
int i, items_count, number, ret_number, rc;
|
||||
struct t_hashtable *hashtable, *ret_hashtable;
|
||||
@ -1807,6 +1807,11 @@ irc_server_sendf (struct t_irc_server *server, int flags, const char *tags,
|
||||
}
|
||||
number++;
|
||||
}
|
||||
if (ret_hashtable)
|
||||
{
|
||||
snprintf (value, sizeof (value), "%d", ret_number - 1);
|
||||
weechat_hashtable_set (ret_hashtable, "count", value);
|
||||
}
|
||||
weechat_hashtable_free (hashtable);
|
||||
if (!rc)
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user