X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=mysql_selector.c;h=ff94d8d7c26e5cc8fcd1095a6e1eb85e17c3a348;hp=f41afcdff61b0f14c518b919028e6ee9d879547d;hb=959d66719258a7b3d5028e5e6770972768621a4f;hpb=4567280e18c11f1f077b00421bca8e25d2dbab83 diff --git a/mysql_selector.c b/mysql_selector.c index f41afcdf..ff94d8d7 100644 --- a/mysql_selector.c +++ b/mysql_selector.c @@ -693,7 +693,7 @@ static char *escaped_basename(const char *name) /* * new attribute */ -static int com_na(__unused int fd, int argc, char *argv[]) +static int com_na(__a_unused int fd, int argc, char *argv[]) { char *q, *tmp; int ret; @@ -714,7 +714,7 @@ static int com_na(__unused int fd, int argc, char *argv[]) /* * delete attribute */ -static int com_da(__unused int fd, int argc, char *argv[]) +static int com_da(__a_unused int fd, int argc, char *argv[]) { char *q, *tmp; int ret; @@ -865,7 +865,7 @@ static void *get_all_attributes(void) /* * list all attributes */ -static int com_laa(int fd, int argc, __unused char *argv[]) +static int com_laa(int fd, int argc, __a_unused char *argv[]) { void *result; int ret; @@ -1465,7 +1465,7 @@ out: /* * remove/add entries */ -static int com_rm_ne(__unused int fd, int argc, char *argv[]) +static int com_rm_ne(__a_unused int fd, int argc, char *argv[]) { int ne = !strcmp(argv[0], "ne"); int i, ret; @@ -1487,7 +1487,7 @@ static int com_rm_ne(__unused int fd, int argc, char *argv[]) /* * mv: rename entry */ -static int com_mv(__unused int fd, int argc, char *argv[]) +static int com_mv(__a_unused int fd, int argc, char *argv[]) { char *q, *dn, *ebn1 = NULL, *ebn2 = NULL, *edn = NULL; int ret; @@ -1545,7 +1545,7 @@ out: * picass: associate pic to audio file * snp: set numplayed */ -static int com_set(__unused int fd, int argc, char *argv[]) +static int com_set(__a_unused int fd, int argc, char *argv[]) { char *q, *ebn; long unsigned id; @@ -1573,7 +1573,7 @@ static int com_set(__unused int fd, int argc, char *argv[]) /* * picch: change entry's name in pics table */ -static int com_picch(__unused int fd, int argc, char *argv[]) +static int com_picch(__a_unused int fd, int argc, char *argv[]) { int ret; long unsigned id; @@ -1596,7 +1596,7 @@ static int com_picch(__unused int fd, int argc, char *argv[]) /* * piclist: print list of pics in db */ -static int com_piclist(__unused int fd, int argc, __unused char *argv[]) +static int com_piclist(__a_unused int fd, int argc, __a_unused char *argv[]) { void *result = NULL; MYSQL_ROW row; @@ -1698,7 +1698,7 @@ out: } /* strdel */ -static int com_strdel(__unused int fd, int argc, char *argv[]) +static int com_strdel(__a_unused int fd, int argc, char *argv[]) { char *q, *tmp; int ret; @@ -1751,7 +1751,7 @@ static int com_ls(int fd, int argc, char *argv[]) /* * summary */ -static int com_summary(__unused int fd, int argc, __unused char *argv[]) +static int com_summary(__a_unused int fd, int argc, __a_unused char *argv[]) { MYSQL_ROW row; MYSQL_ROW row2; @@ -1861,7 +1861,7 @@ static void update_audio_file_server_handler(char *name) update_audio_file(name); } -static int com_us(__unused int fd, int argc, char *argv[]) +static int com_us(__a_unused int fd, int argc, char *argv[]) { char *tmp; int ret; @@ -1892,7 +1892,7 @@ static void refresh_selector_info(void) } /* select previous/next stream */ -static int com_ps(__unused int fd, int argc, char *argv[]) +static int com_ps(__a_unused int fd, int argc, char *argv[]) { char *query, *stream = get_current_stream(); void *result = get_result("select name from streams"); @@ -1959,7 +1959,7 @@ out: } /* streams */ -static int com_streams(int fd, int argc, __unused char *argv[]) +static int com_streams(int fd, int argc, __a_unused char *argv[]) { unsigned int num_rows; int i, ret = -E_NORESULT; @@ -2210,6 +2210,7 @@ no_more_atts: } refresh_selector_info(); out: + free(atts); return ret; } @@ -2264,7 +2265,7 @@ out: /* * verify / clean */ -static int com_vrfy(int fd, int argc, __unused char *argv[]) +static int com_vrfy(int fd, int argc, __a_unused char *argv[]) { char *query; int ret, vrfy_mode = strcmp(argv[0], "clean"); @@ -2330,7 +2331,7 @@ static int mysql_write_tmp_file(const char *dir, const char *name) /* * update database */ -static int com_upd(int fd, int argc, __unused char *argv[]) +static int com_upd(int fd, int argc, __a_unused char *argv[]) { char *tempname = NULL, *query = NULL; int ret, out_fd = -1, num = 0;