about summary refs log tree commit diff stats
path: root/src/command/commands.c
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2015-03-10 21:16:34 +0000
committerJames Booth <boothj5@gmail.com>2015-03-10 21:16:34 +0000
commit2ff6873cf1ad4ca3c78947f5e3372d1da5a0b7d3 (patch)
tree3689896b22e111b8ed21b489cc219d7b0f984f19 /src/command/commands.c
parent3c1e8c4e154600b8b7aeb60bbf316e39a97ece27 (diff)
downloadprofani-tty-2ff6873cf1ad4ca3c78947f5e3372d1da5a0b7d3.tar.gz
Send private carbons element with message when encrypted
Diffstat (limited to 'src/command/commands.c')
-rw-r--r--src/command/commands.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/command/commands.c b/src/command/commands.c
index 8c93b065..2ca749fb 100644
--- a/src/command/commands.c
+++ b/src/command/commands.c
@@ -1265,7 +1265,7 @@ cmd_msg(gchar **args, struct cmd_help_t help)
             if (otr_is_secure(barejid)) {
                 char *encrypted = otr_encrypt_message(barejid, msg);
                 if (encrypted != NULL) {
-                    message_send_chat(barejid, encrypted);
+                    message_send_chat_encrypted(barejid, encrypted);
                     otr_free_message(encrypted);
                     ui_outgoing_chat_msg("me", barejid, msg);
 
@@ -1294,7 +1294,7 @@ cmd_msg(gchar **args, struct cmd_help_t help)
                     GString *otr_message = g_string_new(msg);
                     g_string_append(otr_message, OTRL_MESSAGE_TAG_BASE);
                     g_string_append(otr_message, OTRL_MESSAGE_TAG_V2);
-                    message_send_chat(barejid, otr_message->str);
+                    message_send_chat_encrypted(barejid, otr_message->str);
 
                     g_string_free(otr_message, TRUE);
                 } else {
@@ -3073,7 +3073,7 @@ cmd_tiny(gchar **args, struct cmd_help_t help)
                 if (otr_is_secure(chatwin->barejid)) {
                     char *encrypted = otr_encrypt_message(chatwin->barejid, tiny);
                     if (encrypted != NULL) {
-                        message_send_chat(chatwin->barejid, encrypted);
+                        message_send_chat_encrypted(chatwin->barejid, encrypted);
                         otr_free_message(encrypted);
                         if (prefs_get_boolean(PREF_CHLOG)) {
                             const char *jid = jabber_get_fulljid();
@@ -4080,7 +4080,7 @@ cmd_otr(gchar **args, struct cmd_help_t help)
                     ui_current_print_formatted_line('!', 0, "You have not generated or loaded a private key, use '/otr gen'");
                 } else if (!otr_is_secure(barejid)) {
                     char *otr_query_message = otr_start_query();
-                    message_send_chat(barejid, otr_query_message);
+                    message_send_chat_encrypted(barejid, otr_query_message);
                 } else {
                     ui_gone_secure(barejid, otr_is_trusted(barejid));
                 }
@@ -4098,7 +4098,7 @@ cmd_otr(gchar **args, struct cmd_help_t help)
                 } else {
                     ProfChatWin *chatwin = ui_get_current_chat();
                     char *otr_query_message = otr_start_query();
-                    message_send_chat(chatwin->barejid, otr_query_message);
+                    message_send_chat_encrypted(chatwin->barejid, otr_query_message);
                 }
             }
         }