diff --git a/src/command/cmd_funcs.c b/src/command/cmd_funcs.c index e1ac8d37..bcc6b85c 100644 --- a/src/command/cmd_funcs.c +++ b/src/command/cmd_funcs.c @@ -3418,7 +3418,7 @@ cmd_caps(ProfWin* window, const char* const command, gchar** args) if (args[0]) { auto_jid Jid* jid = jid_create(args[0]); - if (jid->fulljid == NULL) { + if (jid == NULL || jid->fulljid == NULL) { cons_show("You must provide a full jid to the /caps command."); } else { PContact pcontact = roster_get_contact(jid->barejid);