aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/media/UVideo.pas11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/media/UVideo.pas b/src/media/UVideo.pas
index 197fc572..2d3b7620 100644
--- a/src/media/UVideo.pas
+++ b/src/media/UVideo.pas
@@ -532,8 +532,17 @@ begin
end;
// no error -> wait for user input
- SDL_Delay(100);
+{
+ SDL_Delay(100); // initial version, left for documentation
continue;
+}
+
+ // Patch by Hawkear:
+ // Why should this function loop in an endless loop if there is an error?
+ // This runs in the main thread, so it halts the whole program
+ // Therefore, it is better to exit when an error occurs
+ Exit;
+
end;
// if we got a packet from the video stream, then decode it