From 2e6de99f1e1595d56f7a58591b0df8c97059cb0d Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Wed, 21 Apr 2021 20:08:03 +0200 Subject: [PATCH] ImageDecoder: Add missing include and use dbgln_if() --- Userland/Services/ImageDecoder/ClientConnection.cpp | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/Userland/Services/ImageDecoder/ClientConnection.cpp b/Userland/Services/ImageDecoder/ClientConnection.cpp index fd10705aff..0a5af21e5e 100644 --- a/Userland/Services/ImageDecoder/ClientConnection.cpp +++ b/Userland/Services/ImageDecoder/ClientConnection.cpp @@ -24,12 +24,11 @@ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include +#include #include #include #include #include -#include namespace ImageDecoder { @@ -60,18 +59,14 @@ OwnPtr ClientConnection::hand { auto encoded_buffer = message.data(); if (!encoded_buffer.is_valid()) { -#if IMAGE_DECODER_DEBUG - dbgln("Encoded data is invalid"); -#endif + dbgln_if(IMAGE_DECODER_DEBUG, "Encoded data is invalid"); return {}; } auto decoder = Gfx::ImageDecoder::create(encoded_buffer.data(), encoded_buffer.size()); if (!decoder->frame_count()) { -#if IMAGE_DECODER_DEBUG - dbgln("Could not decode image from encoded data"); -#endif + dbgln_if(IMAGE_DECODER_DEBUG, "Could not decode image from encoded data"); return make(false, 0, Vector {}, Vector {}); }