about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--src/command/command.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/command/command.c b/src/command/command.c
index 840ce6a0..d6c8f8b3 100644
--- a/src/command/command.c
+++ b/src/command/command.c
@@ -1974,6 +1974,9 @@ _cmd_msg(gchar **args, struct cmd_help_t help)
 
     } else {
         char *usr_jid = roster_barejid_from_name(usr);
+        if (usr_jid == NULL) {
+            usr_jid = usr;
+        }
         if (msg != NULL) {
             message_send(msg, usr_jid);
             ui_outgoing_msg("me", usr_jid, msg);