191 |
if (!mask || !mask[0] || !type || !type[0] || !channel_name || !channel_name[0] |
if (!mask || !mask[0] || !type || !type[0] || !channel_name || !channel_name[0] |
192 |
|| !server_name || !server_name[0]) |
|| !server_name || !server_name[0]) |
193 |
{ |
{ |
194 |
|
irc_display_prefix (NULL, NULL, PREFIX_ERROR); |
195 |
gui_printf (NULL, |
gui_printf (NULL, |
196 |
_("%s too few arguments for ignore\n"), |
_("%s too few arguments for ignore\n"), |
197 |
WEECHAT_ERROR); |
WEECHAT_ERROR); |
208 |
|
|
209 |
if ((strcmp (mask, "*") == 0) && (strcmp (type, "*") == 0)) |
if ((strcmp (mask, "*") == 0) && (strcmp (type, "*") == 0)) |
210 |
{ |
{ |
211 |
irc_display_prefix (NULL, PREFIX_ERROR); |
irc_display_prefix (NULL, NULL, PREFIX_ERROR); |
212 |
gui_printf (NULL, |
gui_printf (NULL, |
213 |
_("%s mask or type/command should be non generic value for ignore\n"), |
_("%s mask or type/command should be non generic value for ignore\n"), |
214 |
WEECHAT_ERROR); |
WEECHAT_ERROR); |
217 |
|
|
218 |
if (ignore_search (mask, type, channel_name, server_name)) |
if (ignore_search (mask, type, channel_name, server_name)) |
219 |
{ |
{ |
220 |
irc_display_prefix (NULL, PREFIX_ERROR); |
irc_display_prefix (NULL, NULL, PREFIX_ERROR); |
221 |
gui_printf (NULL, |
gui_printf (NULL, |
222 |
_("%s ignore already exists\n"), |
_("%s ignore already exists\n"), |
223 |
WEECHAT_ERROR); |
WEECHAT_ERROR); |
253 |
/* not a pre-defined command and not an IRC command => error */ |
/* not a pre-defined command and not an IRC command => error */ |
254 |
if ((type_index < 0) && (!command_ptr)) |
if ((type_index < 0) && (!command_ptr)) |
255 |
{ |
{ |
256 |
irc_display_prefix (NULL, PREFIX_ERROR); |
irc_display_prefix (NULL, NULL, PREFIX_ERROR); |
257 |
gui_printf (NULL, |
gui_printf (NULL, |
258 |
_("%s unknown type or IRC command \"%s\" for ignore\n"), |
_("%s unknown type or IRC command \"%s\" for ignore\n"), |
259 |
WEECHAT_ERROR, type); |
WEECHAT_ERROR, type); |
281 |
} |
} |
282 |
else |
else |
283 |
{ |
{ |
284 |
irc_display_prefix (NULL, PREFIX_ERROR); |
irc_display_prefix (NULL, NULL, PREFIX_ERROR); |
285 |
gui_printf (NULL, |
gui_printf (NULL, |
286 |
_("%s not enough memory to create ignore\n"), |
_("%s not enough memory to create ignore\n"), |
287 |
WEECHAT_ERROR); |
WEECHAT_ERROR); |
403 |
found++; |
found++; |
404 |
if (found == 1) |
if (found == 1) |
405 |
gui_printf (NULL, "\n"); |
gui_printf (NULL, "\n"); |
406 |
irc_display_prefix (NULL, PREFIX_INFO); |
irc_display_prefix (NULL, NULL, PREFIX_INFO); |
407 |
weechat_cmd_ignore_display (_("Removing ignore:"), ptr_ignore); |
weechat_cmd_ignore_display (_("Removing ignore:"), ptr_ignore); |
408 |
next_ignore = ptr_ignore->next_ignore; |
next_ignore = ptr_ignore->next_ignore; |
409 |
ignore_free (ptr_ignore); |
ignore_free (ptr_ignore); |
439 |
if (i == number) |
if (i == number) |
440 |
{ |
{ |
441 |
gui_printf (NULL, "\n"); |
gui_printf (NULL, "\n"); |
442 |
irc_display_prefix (NULL, PREFIX_INFO); |
irc_display_prefix (NULL, NULL, PREFIX_INFO); |
443 |
weechat_cmd_ignore_display (_("Removing ignore:"), ptr_ignore); |
weechat_cmd_ignore_display (_("Removing ignore:"), ptr_ignore); |
444 |
ignore_free (ptr_ignore); |
ignore_free (ptr_ignore); |
445 |
return 1; |
return 1; |