From 0a1c7b5348396f37998d4220332ee220748b6b01 Mon Sep 17 00:00:00 2001
From: Sam Lantinga <[EMAIL REDACTED]>
Date: Sat, 28 Feb 2026 08:41:47 -0800
Subject: [PATCH] Fixed SDL_GetIOSize() return value
Fixes https://github.com/libsdl-org/SDL/issues/15129
---
src/io/SDL_iostream.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/io/SDL_iostream.c b/src/io/SDL_iostream.c
index 6b1eacd0abccd..8172c8e773360 100644
--- a/src/io/SDL_iostream.c
+++ b/src/io/SDL_iostream.c
@@ -1513,7 +1513,8 @@ SDL_PropertiesID SDL_GetIOProperties(SDL_IOStream *context)
Sint64 SDL_GetIOSize(SDL_IOStream *context)
{
CHECK_PARAM(!context) {
- return SDL_InvalidParamError("context");
+ SDL_InvalidParamError("context");
+ return -1;
}
if (!context->iface.size) {