From fada4c0ee76b8f827dfab9fb984e3fe9c10caf48 Mon Sep 17 00:00:00 2001 From: ejurgensen Date: Mon, 10 Aug 2020 22:08:35 +0200 Subject: [PATCH] [lastfm] Fix incorrect error condition test --- src/lastfm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lastfm.c b/src/lastfm.c index e3168830..2f2c1707 100644 --- a/src/lastfm.c +++ b/src/lastfm.c @@ -230,7 +230,7 @@ request_post(const char *url, struct keyval *kv, char **errmsg) memset(&ctx, 0, sizeof(struct http_client_ctx)); ctx.output_body = http_form_urlencode(kv); - if (ret < 0) + if (!ctx.output_body) { DPRINTF(E_LOG, L_LASTFM, "Aborting request, http_form_urlencode failed\n"); return -1;