commandError() cleanups, fixup gcc checks

stripped binary size reduced by 9k on my machine from making
commandError a function.  We'll print out error messages slightly
slower before, but the smaller binary is more than worth it.

git-svn-id: https://svn.musicpd.org/mpd/trunk@4488 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
Eric Wong
2006-07-30 08:47:50 +00:00
parent a0c8e3656b
commit e86fd65c81
8 changed files with 58 additions and 57 deletions

View File

@@ -671,7 +671,7 @@ int addSongToPlaylist(int fd, Song * song, int printId)
if (playlist.length == playlist_max_length) {
commandError(fd, ACK_ERROR_PLAYLIST_MAX,
"playlist is at the max size", NULL);
"playlist is at the max size");
return -1;
}
@@ -1360,7 +1360,7 @@ int deletePlaylist(int fd, char *utf8file)
if (unlink(actualFile) < 0) {
commandError(fd, ACK_ERROR_SYSTEM,
"problems deleting file", NULL);
"problems deleting file");
return -1;
}
@@ -1407,8 +1407,7 @@ int savePlaylist(int fd, char *utf8file)
while (!(fileP = fopen(actualFile, "w")) && errno == EINTR) ;
if (fileP == NULL) {
commandError(fd, ACK_ERROR_SYSTEM, "problems opening file",
NULL);
commandError(fd, ACK_ERROR_SYSTEM, "problems opening file");
return -1;
}