mirror of
https://github.com/owntone/owntone-server.git
synced 2025-11-25 20:16:14 -05:00
[db] Refactor fetching query result into generic function
Additionally changes the return value in case the end of the result set is reached.
This commit is contained in:
@@ -588,7 +588,7 @@ rsp_reply_playlist(struct httpd_request *hreq)
|
||||
mxmlNewTextf(node, 0, "%d", qp.results);
|
||||
|
||||
/* Items block (all items) */
|
||||
while (((ret = db_query_fetch_file(&qp, &dbmfi)) == 0) && (dbmfi.id))
|
||||
while ((ret = db_query_fetch_file(&qp, &dbmfi)) == 0)
|
||||
{
|
||||
headers = evhttp_request_get_input_headers(hreq->req);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user