diff options
author | Lars-Dominik Braun <lars@6xq.net> | 2011-12-24 12:41:33 +0100 |
---|---|---|
committer | Lars-Dominik Braun <lars@6xq.net> | 2011-12-24 12:41:33 +0100 |
commit | 357153c25547d0e797bbb3d1390a947c4268273e (patch) | |
tree | 309ffe06e1327d0bf0c822f27f5807c933ee0432 /src/libpiano | |
parent | ec635afff07654f4b43ba0859ddeff43bd9315fb (diff) | |
download | pianobar-windows-357153c25547d0e797bbb3d1390a947c4268273e.tar.gz pianobar-windows-357153c25547d0e797bbb3d1390a947c4268273e.tar.bz2 pianobar-windows-357153c25547d0e797bbb3d1390a947c4268273e.zip |
Fix warnings found by -Wwrite-strings
Can’t fix all of them; ezxml is a mess :(
Diffstat (limited to 'src/libpiano')
-rw-r--r-- | src/libpiano/xml.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/libpiano/xml.c b/src/libpiano/xml.c index 1f6eed7..de05122 100644 --- a/src/libpiano/xml.c +++ b/src/libpiano/xml.c @@ -691,9 +691,10 @@ PianoReturn_t PianoXmlParseSeedSuggestions (char *xml, * @return encoded string or NULL */ char *PianoXmlEncodeString (const char *s) { - char *replacements[] = {"&&", "''", "\""", "<<", - ">>", NULL}; - char **r, *sOut, *sOutCurr, found; + static const char *replacements[] = {"&&", "''", "\""", + "<<", ">>", NULL}; + const char **r; + char *sOut, *sOutCurr, found; if ((sOut = calloc (strlen (s) * 5 + 1, sizeof (*sOut))) == NULL) { return NULL; |