aboutsummaryrefslogtreecommitdiffstats
path: root/src/main.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-10-28 20:33:56 +0100
committerMax Kellermann <max@duempel.org>2008-10-28 20:33:56 +0100
commit016d996131d560db6d72476ae29c74df84746fff (patch)
treec22a7d13e1b39927e70e73cbc8f78762fba0d92a /src/main.c
parent4a71f66256d02c46bc2bb3665cc6451a2101d5ac (diff)
downloadmpd-016d996131d560db6d72476ae29c74df84746fff.tar.gz
mpd-016d996131d560db6d72476ae29c74df84746fff.tar.xz
mpd-016d996131d560db6d72476ae29c74df84746fff.zip
utils: use g_str_has_prefix() instead of prefixcmp()
Remove duplicated code from MPD.
Diffstat (limited to '')
-rw-r--r--src/main.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c
index 77d59a6af..025570f84 100644
--- a/src/main.c
+++ b/src/main.c
@@ -46,12 +46,13 @@
#include "tag.h"
#include "dbUtils.h"
#include "../config.h"
-#include "utils.h"
#include "normalize.h"
#include "zeroconf.h"
#include "main_notify.h"
#include "os_compat.h"
+#include <glib.h>
+
#define SYSTEM_CONFIG_FILE_LOCATION "/etc/mpd.conf"
#define USER_CONFIG_FILE_LOCATION "/.mpdconf"
@@ -156,7 +157,7 @@ static void parseOptions(int argc, char **argv, Options * options)
if (argc > 1) {
int i = 1;
while (i < argc) {
- if (!prefixcmp(argv[i], "--")) {
+ if (g_str_has_prefix(argv[i], "--")) {
if (strcmp(argv[i], "--help") == 0) {
usage(argv);
exit(EXIT_SUCCESS);