From 1dab91e47311c94cb3c4643d6e370d25ee9d55a8 Mon Sep 17 00:00:00 2001 From: reuk Date: Mon, 23 Jun 2025 17:20:32 +0100 Subject: [PATCH] WebBrowserComponent: Avoid spinning indefinitely when reaching end of file --- .../juce_gui_extra/native/juce_WebBrowserComponent_linux.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/juce_gui_extra/native/juce_WebBrowserComponent_linux.cpp b/modules/juce_gui_extra/native/juce_WebBrowserComponent_linux.cpp index c01217216c..f2e8a95d1c 100644 --- a/modules/juce_gui_extra/native/juce_WebBrowserComponent_linux.cpp +++ b/modules/juce_gui_extra/native/juce_WebBrowserComponent_linux.cpp @@ -547,9 +547,9 @@ private: { const auto bytesThisTime = read (inChannel, target.data() + pos, target.size() - pos); - if (bytesThisTime < 0) + if (bytesThisTime <= 0) { - if (errno == EINTR) + if (bytesThisTime != 0 && errno == EINTR) continue; break;