diff options
author | Max Kellermann <max@musicpd.org> | 2017-02-08 09:58:20 +0100 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2017-02-08 09:59:12 +0100 |
commit | d184231169687025200e189afe898d955fa095cb (patch) | |
tree | 7a097eb48fad26bec07f0000059987a6e789ffd0 /src/db/DatabaseSong.cxx | |
parent | 7225e919fc181eb34908f6b681127a9df781a34d (diff) |
db/DatabaseSong: DatabaseDetachSong(uri) returns instance, not pointer
Diffstat (limited to 'src/db/DatabaseSong.cxx')
-rw-r--r-- | src/db/DatabaseSong.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/db/DatabaseSong.cxx b/src/db/DatabaseSong.cxx index aadc0bee4..ca39ffa49 100644 --- a/src/db/DatabaseSong.cxx +++ b/src/db/DatabaseSong.cxx @@ -41,7 +41,7 @@ DatabaseDetachSong(const Storage &storage, const LightSong &song) return detached; } -DetachedSong * +DetachedSong DatabaseDetachSong(const Database &db, const Storage &storage, const char *uri) { const LightSong *tmp = db.GetSong(uri); @@ -49,5 +49,5 @@ DatabaseDetachSong(const Database &db, const Storage &storage, const char *uri) AtScopeExit(&db, tmp) { db.ReturnSong(tmp); }; - return new DetachedSong(DatabaseDetachSong(storage, *tmp)); + return DatabaseDetachSong(storage, *tmp); } |