diff options
author | Max Kellermann <max@duempel.org> | 2014-02-01 00:26:34 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2014-02-04 11:22:33 +0100 |
commit | cf6281a5a758e4b93d67f7fd5804a8cff60ddbf9 (patch) | |
tree | 7368011b1ecf5ae6db6dcafb676fddf03ff9d823 /src/SongLoader.cxx | |
parent | f00710a57e80738c33255eaa1347ab776fbce869 (diff) |
Instance: add Database attribute
Move from db/DatabaseGlue.cxx, eliminating global variable.
Diffstat (limited to 'src/SongLoader.cxx')
-rw-r--r-- | src/SongLoader.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/SongLoader.cxx b/src/SongLoader.cxx index 90df42824..08aa01296 100644 --- a/src/SongLoader.cxx +++ b/src/SongLoader.cxx @@ -33,6 +33,13 @@ #include <assert.h> #include <string.h> +#ifdef ENABLE_DATABASE + +SongLoader::SongLoader(const Client &_client) + :client(&_client), db(_client.GetDatabase(IgnoreError())) {} + +#endif + DetachedSong * SongLoader::LoadFile(const char *path_utf8, Error &error) const { |