From a86f9b80357e30823ce9d3d486adcf4cd4e781dc Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sun, 20 Sep 2009 23:31:35 +0200 Subject: cmdline: removed options --create-db and --no-create-db Both options are deprecated, and should not be used anymore. Many users get confused by their presence. --- src/cmdline.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'src/cmdline.c') diff --git a/src/cmdline.c b/src/cmdline.c index 606f26674..d0e8e75da 100644 --- a/src/cmdline.c +++ b/src/cmdline.c @@ -82,17 +82,13 @@ void parse_cmdline(int argc, char **argv, struct options *options) GOptionContext *context; bool ret; static gboolean option_version, - option_create_db, option_no_create_db, option_no_daemon, + option_no_daemon, option_no_config; const GOptionEntry entries[] = { - { "create-db", 0, 0, G_OPTION_ARG_NONE, &option_create_db, - "force (re)creation of database", NULL }, { "kill", 0, 0, G_OPTION_ARG_NONE, &options->kill, "kill the currently running mpd session", NULL }, { "no-config", 0, 0, G_OPTION_ARG_NONE, &option_no_config, "don't read from config", NULL }, - { "no-create-db", 0, 0, G_OPTION_ARG_NONE, &option_no_create_db, - "don't create database, even if it doesn't exist", NULL }, { "no-daemon", 0, 0, G_OPTION_ARG_NONE, &option_no_daemon, "don't detach from console", NULL }, { "stdout", 0, 0, G_OPTION_ARG_NONE, &options->log_stderr, @@ -110,7 +106,6 @@ void parse_cmdline(int argc, char **argv, struct options *options) options->daemon = true; options->log_stderr = false; options->verbose = false; - options->create_db = 0; context = g_option_context_new("[path/to/mpd.conf]"); g_option_context_add_main_entries(context, entries, NULL); @@ -134,14 +129,6 @@ void parse_cmdline(int argc, char **argv, struct options *options) parser can use it already */ log_early_init(options->verbose); - if (option_create_db && option_no_create_db) - g_error("Cannot use both --create-db and --no-create-db\n"); - - if (option_no_create_db) - options->create_db = -1; - else if (option_create_db) - options->create_db = 1; - options->daemon = !option_no_daemon; if (option_no_config) { -- cgit v1.2.3