equal
deleted
inserted
replaced
64 char **args = split_arg (arg, 2, 1); |
64 char **args = split_arg (arg, 2, 1); |
65 char *cmd = NULL; |
65 char *cmd = NULL; |
66 char *jid = NULL; |
66 char *jid = NULL; |
67 gboolean jfree = FALSE; |
67 gboolean jfree = FALSE; |
68 int marked = -1; |
68 int marked = -1; |
|
69 guint len; |
69 |
70 |
70 if (args[0]) { |
71 if (args[0]) { |
71 cmd = args[0]; |
72 cmd = args[0]; |
72 |
73 |
73 if (args[1]) { |
74 if (args[1]) { |
138 marked = 1; |
139 marked = 1; |
139 jfree = FALSE; |
140 jfree = FALSE; |
140 } |
141 } |
141 } |
142 } |
142 |
143 |
|
144 len = g_slist_length(marked_jids); |
143 if (marked == 1) { |
145 if (marked == 1) { |
144 scr_write_incoming_message (jid, "Marked", 0, |
146 scr_write_incoming_message (jid, "Marked", 0, |
145 HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG, 0); |
147 HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG, 0); |
146 } else if (marked == 0) { |
148 } else if (marked == 0) { |
147 scr_write_incoming_message (jid, "Mark cleared", 0, |
149 scr_write_incoming_message (jid, "Mark cleared", 0, |
148 HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG, 0); |
150 HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG, 0); |
|
151 } |
|
152 if (marked >= 0) { |
|
153 scr_LogPrint(LPRINT_NORMAL, "<%s> is now %s (%u mark%s).", jid, |
|
154 marked == 1 ? "marked" : "unmarked", |
|
155 len, len > 1 ? "s" : ""); |
149 } |
156 } |
150 |
157 |
151 if (jfree && jid) |
158 if (jfree && jid) |
152 g_free (jid); |
159 g_free (jid); |
153 |
160 |