aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/command.c4
-rw-r--r--src/conf.c4
-rw-r--r--src/normalize.c4
-rw-r--r--src/sllist.h2
-rw-r--r--src/tag.c6
5 files changed, 11 insertions, 9 deletions
diff --git a/src/command.c b/src/command.c
index b43882178..b063f8a0e 100644
--- a/src/command.c
+++ b/src/command.c
@@ -1141,7 +1141,7 @@ static CommandEntry *getCommandEntryAndCheckArgcAndPermission(int fd,
static CommandEntry *getCommandEntryFromString(char *string, int *permission)
{
CommandEntry *cmd = NULL;
- char *argv[COMMAND_ARGV_MAX] = { 0 };
+ char *argv[COMMAND_ARGV_MAX] = { NULL };
int argc = cstrtok(string, argv, COMMAND_ARGV_MAX);
if (0 == argc)
@@ -1157,7 +1157,7 @@ static int processCommandInternal(int fd, int *permission,
char *commandString, struct strnode *cmdnode)
{
int argc;
- char *argv[COMMAND_ARGV_MAX] = { 0 };
+ char *argv[COMMAND_ARGV_MAX] = { NULL };
CommandEntry *cmd;
int ret = -1;
diff --git a/src/conf.c b/src/conf.c
index 2ba49ae52..bea4e2c08 100644
--- a/src/conf.c
+++ b/src/conf.c
@@ -199,7 +199,7 @@ static ConfigParam *readConfigBlock(FILE * fp, int *count, char *string)
int argsMinusComment;
while (myFgets(string, MAX_STRING_SIZE, fp)) {
- char *array[CONF_LINE_TOKEN_MAX] = { 0 };
+ char *array[CONF_LINE_TOKEN_MAX] = { NULL };
(*count)++;
@@ -262,7 +262,7 @@ void readConf(char *file)
}
while (myFgets(string, MAX_STRING_SIZE, fp)) {
- char *array[CONF_LINE_TOKEN_MAX] = { 0 };
+ char *array[CONF_LINE_TOKEN_MAX] = { NULL };
count++;
numberOfArgs = cstrtok(string, array, CONF_LINE_TOKEN_MAX);
diff --git a/src/normalize.c b/src/normalize.c
index 31394cbfb..c626d7fd5 100644
--- a/src/normalize.c
+++ b/src/normalize.c
@@ -24,7 +24,7 @@
int normalizationEnabled;
-void initNormalization()
+void initNormalization(void)
{
normalizationEnabled = getBoolConfigParam(CONF_VOLUME_NORMALIZATION);
if (normalizationEnabled == -1) normalizationEnabled = 0;
@@ -34,7 +34,7 @@ void initNormalization()
CompressCfg(0, ANTICLIP, TARGET, GAINMAX, GAINSMOOTH, BUCKETS);
}
-void finishNormalization()
+void finishNormalization(void)
{
if (normalizationEnabled) CompressFree();
}
diff --git a/src/sllist.h b/src/sllist.h
index 1733e955a..4029f16a0 100644
--- a/src/sllist.h
+++ b/src/sllist.h
@@ -3,6 +3,8 @@
#ifndef SLLIST_H
#define SLLIST_H
+#include <stddef.h>
+
/* just free the entire structure if it's free-able, the 'data' member
* should _NEVER_ be explicitly freed
*
diff --git a/src/tag.c b/src/tag.c
index e2ade9fcf..ae0c3c87c 100644
--- a/src/tag.c
+++ b/src/tag.c
@@ -169,17 +169,17 @@ MpdTag *getID3Info(struct id3_tag *tag, char *id, int type, MpdTag * mpdTag)
encoding = getConfigParamValue(CONF_ID3V1_ENCODING);
if (encoding) {
setCharSetConversion("ISO-8859-1", "UTF-8");
- isostr = convStrDup(utf8);
+ isostr = convStrDup((char *)utf8);
free(utf8);
setCharSetConversion("UTF-8", encoding);
- utf8 = convStrDup(isostr);
+ utf8 = (id3_utf8_t *)convStrDup(isostr);
free(isostr);
}
}
if (mpdTag == NULL)
mpdTag = newMpdTag();
- addItemToMpdTag(mpdTag, type, utf8);
+ addItemToMpdTag(mpdTag, type, (char *)utf8);
free(utf8);
}