aboutsummaryrefslogtreecommitdiffstats
path: root/src/ConfigGlobal.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-09-05 18:20:52 +0200
committerMax Kellermann <max@duempel.org>2013-09-05 18:26:46 +0200
commit7a4c9f5f4c38b568a51ec13988f5fcfbbe278afa (patch)
tree03c6b14d6d54f4657aa5939982aec7f942e47c46 /src/ConfigGlobal.cxx
parent3330aa6f6a7fcd903f74cb8342f315ad35b54ead (diff)
downloadmpd-7a4c9f5f4c38b568a51ec13988f5fcfbbe278afa.tar.gz
mpd-7a4c9f5f4c38b568a51ec13988f5fcfbbe278afa.tar.xz
mpd-7a4c9f5f4c38b568a51ec13988f5fcfbbe278afa.zip
mpd_error.h: remove obsolete header
Migrate the remaining callers to FatalError().
Diffstat (limited to 'src/ConfigGlobal.cxx')
-rw-r--r--src/ConfigGlobal.cxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/ConfigGlobal.cxx b/src/ConfigGlobal.cxx
index 07c5ddd96..11e53fc3c 100644
--- a/src/ConfigGlobal.cxx
+++ b/src/ConfigGlobal.cxx
@@ -25,7 +25,7 @@
#include "ConfigPath.hxx"
#include "fs/Path.hxx"
#include "util/Error.hxx"
-#include "mpd_error.h"
+#include "system/FatalError.hxx"
#include <glib.h>
@@ -125,8 +125,8 @@ config_get_unsigned(ConfigOption option, unsigned default_value)
value = strtol(param->value, &endptr, 0);
if (*endptr != 0 || value < 0)
- MPD_ERROR("Not a valid non-negative number in line %i",
- param->line);
+ FormatFatalError("Not a valid non-negative number in line %i",
+ param->line);
return (unsigned)value;
}
@@ -143,10 +143,11 @@ config_get_positive(ConfigOption option, unsigned default_value)
value = strtol(param->value, &endptr, 0);
if (*endptr != 0)
- MPD_ERROR("Not a valid number in line %i", param->line);
+ FormatFatalError("Not a valid number in line %i", param->line);
if (value <= 0)
- MPD_ERROR("Not a positive number in line %i", param->line);
+ FormatFatalError("Not a positive number in line %i",
+ param->line);
return (unsigned)value;
}
@@ -162,9 +163,9 @@ config_get_bool(ConfigOption option, bool default_value)
success = get_bool(param->value, &value);
if (!success)
- MPD_ERROR("Expected boolean value (yes, true, 1) or "
- "(no, false, 0) on line %i\n",
- param->line);
+ FormatFatalError("Expected boolean value (yes, true, 1) or "
+ "(no, false, 0) on line %i\n",
+ param->line);
return value;
}