From edf615ddbbc40eee692080f74bcf8feb99ec6b04 Mon Sep 17 00:00:00 2001
From: Tyler Morgan <[EMAIL REDACTED]>
Date: Tue, 30 May 2023 20:08:53 +0200
Subject: [PATCH] video: Revert SDL_SetPalette no-op return change
Revert incorrect change, see #294
---
src/SDL12_compat.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/SDL12_compat.c b/src/SDL12_compat.c
index 996ff34a5..5b4536a4e 100644
--- a/src/SDL12_compat.c
+++ b/src/SDL12_compat.c
@@ -7303,16 +7303,16 @@ SDL_SetPalette(SDL12_Surface *surface12, int flags, const SDL_Color *colors,
int i, retval;
if (!surface12) {
- return 1; /* not an error, a no-op. */
+ return 0; /* not an error, a no-op. */
}
if ((flags & (SDL12_LOGPAL | SDL12_PHYSPAL)) == 0) {
- return 1; /* nothing to do. */
+ return 0; /* nothing to do. */
}
palette12 = surface12->format->palette;
if (!palette12) {
- return 1; /* not an error, a no-op. */
+ return 0; /* not an error, a no-op. */
}
palette20 = surface12->surface20->format->palette;