diff options
author | Max Kellermann <max@duempel.org> | 2013-10-30 09:37:20 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-10-30 09:37:20 +0100 |
commit | 1ed321f9647b88c1489d7f81095fbf6156d24454 (patch) | |
tree | 8a3e5b98d7ad2034868673255570cac40e8d4847 /src/db/ProxyDatabasePlugin.cxx | |
parent | 2aee1b86f364dfc9d897939081eb4f0403f9a729 (diff) | |
download | mpd-1ed321f9647b88c1489d7f81095fbf6156d24454.tar.gz mpd-1ed321f9647b88c1489d7f81095fbf6156d24454.tar.xz mpd-1ed321f9647b88c1489d7f81095fbf6156d24454.zip |
db/proxy: add missing nullptr check
Diffstat (limited to '')
-rw-r--r-- | src/db/ProxyDatabasePlugin.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/db/ProxyDatabasePlugin.cxx b/src/db/ProxyDatabasePlugin.cxx index c0c9f93e7..b8b660b44 100644 --- a/src/db/ProxyDatabasePlugin.cxx +++ b/src/db/ProxyDatabasePlugin.cxx @@ -194,7 +194,8 @@ ProxyDatabase::GetSong(const char *uri, Error &error) const Song *song2 = song != nullptr ? Convert(song) : nullptr; - mpd_song_free(song); + if (song != nullptr) + mpd_song_free(song); if (!mpd_response_finish(connection)) { if (song2 != nullptr) song2->Free(); |