debug messages no longer cause segfaults :P
git-svn-id: https://svn.musicpd.org/mpd/trunk@3553 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
8
src/ls.c
8
src/ls.c
@@ -278,11 +278,9 @@ InputPlugin * hasMusicSuffix(char * utf8file) {
|
|||||||
|
|
||||||
InputPlugin * isMusic(char * utf8file, time_t * mtime) {
|
InputPlugin * isMusic(char * utf8file, time_t * mtime) {
|
||||||
if(isFile(utf8file,mtime)) {
|
if(isFile(utf8file,mtime)) {
|
||||||
InputPlugin *plugin = hasMusicSuffix(utf8file);
|
InputPlugin * plugin = hasMusicSuffix(utf8file);
|
||||||
if (plugin == NULL) {
|
if (plugin != NULL)
|
||||||
DEBUG("isMusic: %s is not a supported music file\n");
|
return plugin;
|
||||||
}
|
|
||||||
return plugin;
|
|
||||||
}
|
}
|
||||||
DEBUG("isMusic: %s is not a valid file\n",utf8file);
|
DEBUG("isMusic: %s is not a valid file\n",utf8file);
|
||||||
return NULL;
|
return NULL;
|
||||||
|
@@ -50,7 +50,7 @@ Song * newSong(char * url, int type, Directory * parentDir) {
|
|||||||
Song * song = NULL;
|
Song * song = NULL;
|
||||||
|
|
||||||
if(strchr(url, '\n')) {
|
if(strchr(url, '\n')) {
|
||||||
DEBUG("newSong: '%s' is not a valid uri\n");
|
DEBUG("newSong: '%s' is not a valid uri\n",url);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user