db/simple: use C++11 initializer

This commit is contained in:
Max Kellermann 2019-02-22 14:52:01 +01:00
parent d5983dd362
commit 3ada464020
2 changed files with 2 additions and 3 deletions

View File

@ -60,8 +60,7 @@ inline SimpleDatabase::SimpleDatabase(const ConfigBlock &block)
#ifdef ENABLE_ZLIB
compress(block.GetBlockValue("compress", true)),
#endif
cache_path(block.GetPath("cache_directory")),
prefixed_light_song(nullptr)
cache_path(block.GetPath("cache_directory"))
{
if (path.IsNull())
throw std::runtime_error("No \"path\" parameter specified");

View File

@ -58,7 +58,7 @@ class SimpleDatabase : public Database {
* A buffer for GetSong() when prefixing the #LightSong
* instance from a mounted #Database.
*/
mutable PrefixedLightSong *prefixed_light_song;
mutable PrefixedLightSong *prefixed_light_song = nullptr;
/**
* A buffer for GetSong().