Make album groups persistent

Store groups (only album groups supported at the moment) in the DB,
so their ids are persistent for the duration of the forked-daapd session.

Those ids are used to, among other things, retrieve artwork, so we must
provide ourselves some persistence here.

This brings us to schema version 8.
This commit is contained in:
Julien BLACHE
2010-03-06 18:56:30 +01:00
parent 88dde32fc7
commit 224ef48137
4 changed files with 79 additions and 9 deletions

View File

@@ -2044,7 +2044,10 @@ daap_reply_groups(struct evhttp_request *req, struct evbuffer *evbuf, char **uri
dmap_add_string(group, "asaa", dbgri.songalbumartist);
/* Item id (miid) */
dmap_add_int(group, "miid", ngrp);
val = 0;
ret = safe_atoi32(dbgri.id, &val);
if ((ret == 0) && (val > 0))
dmap_add_int(group, "miid", val);
DPRINTF(E_DBG, L_DAAP, "Done with group\n");