mirror of
https://github.com/owntone/owntone-server.git
synced 2025-01-28 15:06:02 -05:00
Remove unused db_file_fetch_bypath()
This commit is contained in:
parent
0ad20e5220
commit
3cadbdb1e3
24
src/db.c
24
src/db.c
@ -1182,30 +1182,6 @@ db_file_fetch_byid(int id)
|
|||||||
#undef Q_TMPL
|
#undef Q_TMPL
|
||||||
}
|
}
|
||||||
|
|
||||||
struct media_file_info *
|
|
||||||
db_file_fetch_bypath(char *path)
|
|
||||||
{
|
|
||||||
#define Q_TMPL "SELECT * FROM songs WHERE path = '%q';"
|
|
||||||
struct media_file_info *mfi;
|
|
||||||
char *query;
|
|
||||||
|
|
||||||
query = sqlite3_mprintf(Q_TMPL, path);
|
|
||||||
if (!query)
|
|
||||||
{
|
|
||||||
DPRINTF(E_LOG, L_DB, "Out of memory for query string\n");
|
|
||||||
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
mfi = db_file_fetch_byquery(query);
|
|
||||||
|
|
||||||
sqlite3_free(query);
|
|
||||||
|
|
||||||
return mfi;
|
|
||||||
|
|
||||||
#undef Q_TMPL
|
|
||||||
}
|
|
||||||
|
|
||||||
int
|
int
|
||||||
db_file_add(struct media_file_info *mfi)
|
db_file_add(struct media_file_info *mfi)
|
||||||
{
|
{
|
||||||
|
3
src/db.h
3
src/db.h
@ -237,9 +237,6 @@ db_file_stamp_bypath(char *path);
|
|||||||
struct media_file_info *
|
struct media_file_info *
|
||||||
db_file_fetch_byid(int id);
|
db_file_fetch_byid(int id);
|
||||||
|
|
||||||
struct media_file_info *
|
|
||||||
db_file_fetch_bypath(char *path);
|
|
||||||
|
|
||||||
int
|
int
|
||||||
db_file_add(struct media_file_info *mfi);
|
db_file_add(struct media_file_info *mfi);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user