diff options
author | Max Kellermann <max@duempel.org> | 2012-08-16 00:29:10 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2012-08-16 00:29:25 +0200 |
commit | 31009bb1f6052fb3c6a41e3a97fdf09405cd577d (patch) | |
tree | 0758a49121a73b31a8f89b115d595d469112c1ce /src | |
parent | 3b8532f3fb379c7ecc6b64eecbbf9c824d18e875 (diff) | |
download | mpd-31009bb1f6052fb3c6a41e3a97fdf09405cd577d.tar.gz mpd-31009bb1f6052fb3c6a41e3a97fdf09405cd577d.tar.xz mpd-31009bb1f6052fb3c6a41e3a97fdf09405cd577d.zip |
ProxyDatabase: clear libmpdclient errors in CheckError()
Auto-recover from soft errors.
Diffstat (limited to 'src')
-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 e27ca8291..5604daf10 100644 --- a/src/db/ProxyDatabasePlugin.cxx +++ b/src/db/ProxyDatabasePlugin.cxx @@ -120,7 +120,7 @@ Convert(enum tag_type tag_type) } static bool -CheckError(const struct mpd_connection *connection, GError **error_r) +CheckError(struct mpd_connection *connection, GError **error_r) { const auto error = mpd_connection_get_error(connection); if (error == MPD_ERROR_SUCCESS) @@ -128,6 +128,7 @@ CheckError(const struct mpd_connection *connection, GError **error_r) g_set_error_literal(error_r, libmpdclient_quark(), (int)error, mpd_connection_get_error_message(connection)); + mpd_connection_clear_error(connection); return false; } |