From ef6c500edb7dc1a4eb9bff11b83b57dd60d37d4a Mon Sep 17 00:00:00 2001 From: Warren Dukes Date: Fri, 4 Jun 2004 00:49:33 +0000 Subject: clean up ACK error coding a little bit git-svn-id: https://svn.musicpd.org/mpd/trunk@1321 09075e82-0dd4-0310-85a5-a0d7c8717e4f --- src/tables.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/tables.c') diff --git a/src/tables.c b/src/tables.c index 4129c1d29..114f71d15 100644 --- a/src/tables.c +++ b/src/tables.c @@ -172,8 +172,7 @@ int printAllAlbums(FILE * fp, char * artist) { } } else { - myfprintf(fp,"%s artist \"%s\" not found\n", - COMMAND_RESPOND_ERROR,artist); + commandError(fp, "artist \"%s\" not found", artist); return -1; } } @@ -184,7 +183,7 @@ int printAllAlbums(FILE * fp, char * artist) { int printAllKeysOfTable(FILE * fp, char * table, char * arg1) { if(strcmp(table,TABLES_ARTIST)==0) { if(arg1!=NULL) { - myfprintf(fp,"%s %s table takes no args\n",COMMAND_RESPOND_ERROR,table); + commandError(fp, "%s table takes no args", table); return -1; } return printAllArtists(fp); @@ -193,8 +192,8 @@ int printAllKeysOfTable(FILE * fp, char * table, char * arg1) { return printAllAlbums(fp,arg1); } else { - myfprintf(fp,"%s table \"%s\" does not exist or not available for listing\n",COMMAND_RESPOND_ERROR,table); + commandError(fp, "table \"%s\" does not exist or not available " + "for listing", table); return -1; } } -/* vim:set shiftwidth=4 tabstop=8 expandtab: */ -- cgit v1.2.3