about summary refs log tree commit diff stats
path: root/src/command
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2013-05-19 23:35:02 +0100
committerJames Booth <boothj5@gmail.com>2013-05-19 23:35:02 +0100
commit59a3a5fe9b579bf76caf594c934fd1a8a9cb46ac (patch)
treef2c65b22d2d7697a0790df8de10a34905293ea1d /src/command
parentad6184c86bf65e7436ad0377d3e77985cff1d2fd (diff)
downloadprofani-tty-59a3a5fe9b579bf76caf594c934fd1a8a9cb46ac.tar.gz
Use handle in /msg command
Diffstat (limited to 'src/command')
-rw-r--r--src/command/command.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/command/command.c b/src/command/command.c
index 2eb0adc0..53bc39c0 100644
--- a/src/command/command.c
+++ b/src/command/command.c
@@ -1973,14 +1973,15 @@ _cmd_msg(gchar **args, struct cmd_help_t help)
         return TRUE;
 
     } else {
+        char *usr_jid = roster_jid_from_handle(usr);
         if (msg != NULL) {
-            message_send(msg, usr);
-            ui_outgoing_msg("me", usr, msg);
+            message_send(msg, usr_jid);
+            ui_outgoing_msg("me", usr_jid, msg);
 
             if (((win_type == WIN_CHAT) || (win_type == WIN_CONSOLE)) && prefs_get_boolean(PREF_CHLOG)) {
                 const char *jid = jabber_get_jid();
                 Jid *jidp = jid_create(jid);
-                chat_log_chat(jidp->barejid, usr, msg, PROF_OUT_LOG, NULL);
+                chat_log_chat(jidp->barejid, usr_jid, msg, PROF_OUT_LOG, NULL);
                 jid_destroy(jidp);
             }