degesch: fix /server add

This commit is contained in:
Přemysl Eric Janouch 2015-07-12 23:32:03 +02:00
parent b9241bdef9
commit 606f0b1faa

View File

@ -7466,11 +7466,11 @@ show_servers_list (struct app_context *ctx)
static bool
handle_server_add (struct handler_args *a)
{
char *name = cut_word (&a->arguments);
if (!*a->arguments)
return false;
struct app_context *ctx = a->ctx;
char *name = cut_word (&a->arguments);
if (check_server_name_for_addition (ctx, name))
server_add_new (ctx, name);
return true;