diff --git a/src/dispatch.c b/src/dispatch.c index 45af0bce..55deb584 100644 --- a/src/dispatch.c +++ b/src/dispatch.c @@ -897,7 +897,7 @@ void dispatch_addplaylistitems(WS_CONNINFO *pwsc, DBQUERYINFO *pqi) { tempstring=strdup(ws_getvar(pwsc,"dmap.itemid")); current=(unsigned char*)tempstring; - while((token=strsep((char**)¤t,","))) { + while((token=strsep((char**)(char*)¤t,","))) { if(token) { /* FIXME: error handling */ db_add_playlist_item(NULL,pqi->playlist_id,atoi(token)); @@ -968,7 +968,8 @@ void dispatch_deleteplaylistitems(WS_CONNINFO *pwsc, DBQUERYINFO *pqi) { tempstring=strdup(ws_getvar(pwsc,"dmap.itemid")); current=(unsigned char *)tempstring; - while((token=strsep((char**)¤t,","))) { + /* this looks strange, but gets rid of gcc 4 warnings */ + while((token=strsep((char**)(char*)¤t,","))) { if(token) { /* FIXME: Error handling */ db_delete_playlist_item(NULL,pqi->playlist_id,atoi(token));