Mercurial > ~mikael > mcabber > hg
comparison mcabber/mcabber/commands.c @ 1725:318c64ceb494
Do not rename a contact before the server's ACK
(The server could deny the request... Cf. Facebook chat.)
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Sun, 28 Feb 2010 13:31:57 +0100 |
parents | b18142457ca9 |
children | 98917ddcbaab |
comparison
equal
deleted
inserted
replaced
1724:0fa71bfe703d | 1725:318c64ceb494 |
---|---|
2038 } else { | 2038 } else { |
2039 // Rename a single buddy | 2039 // Rename a single buddy |
2040 guint del_name = 0; | 2040 guint del_name = 0; |
2041 if (!*newname || !strcmp(arg, "-")) | 2041 if (!*newname || !strcmp(arg, "-")) |
2042 del_name = TRUE; | 2042 del_name = TRUE; |
2043 buddy_setname(bud, (del_name ? (char*)bjid : name_utf8)); | 2043 /* We do not rename the buddy right now because the server could reject |
2044 * the request. Let's wait for the server answer. | |
2045 * buddy_setname(bud, (del_name ? (char*)bjid : name_utf8)); | |
2046 */ | |
2044 xmpp_updatebuddy(bjid, (del_name ? NULL : name_utf8), group); | 2047 xmpp_updatebuddy(bjid, (del_name ? NULL : name_utf8), group); |
2045 } | 2048 } |
2046 | 2049 |
2047 g_free(name_utf8); | 2050 g_free(name_utf8); |
2048 g_free(newname); | 2051 g_free(newname); |