From f189dbc687843603e33cc950af3c158becf21a60 Mon Sep 17 00:00:00 2001 From: James Booth Date: Fri, 16 Jun 2017 00:59:21 +0100 Subject: Only send ping requests to client that support it --- src/command/cmd_funcs.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src') diff --git a/src/command/cmd_funcs.c b/src/command/cmd_funcs.c index 42553f5a..6409ec54 100644 --- a/src/command/cmd_funcs.c +++ b/src/command/cmd_funcs.c @@ -5868,6 +5868,11 @@ cmd_ping(ProfWin *window, const char *const command, gchar **args) return TRUE; } + if (args[0] != NULL && caps_jid_has_feature(args[0], XMPP_FEATURE_PING) == FALSE) { + cons_show("%s does not support ping requests.", args[0]); + return TRUE; + } + iq_send_ping(args[0]); if (args[0] == NULL) { -- cgit 1.4.1-2-gfad0