The patch
From 3a940ba8eecc5d4d897d84046a60622300b6a406 Mon Sep 17 00:00:00 2001
From: Sam Lantinga <[EMAIL REDACTED]>
Date: Wed, 14 Dec 2022 09:59:56 -0800
Subject: [PATCH] Updated gendynapi.py to handle thread-safety annotations
---
src/dynapi/gendynapi.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/dynapi/gendynapi.py b/src/dynapi/gendynapi.py
index 7dd922ce22d6..d60fd16822fc 100755
--- a/src/dynapi/gendynapi.py
+++ b/src/dynapi/gendynapi.py
@@ -147,6 +147,9 @@ def main():
func = func.replace("SDL_MALLOC", "");
func = func.replace("SDL_ALLOC_SIZE2(1, 2)", "");
func = func.replace("SDL_ALLOC_SIZE(2)", "");
+ func = re.sub(" SDL_ACQUIRE\(.*\)", "", func);
+ func = re.sub(" SDL_TRY_ACQUIRE\(.*\)", "", func);
+ func = re.sub(" SDL_RELEASE\(.*\)", "", func);
# Should be a valid function here
match = reg_parsing_function.match(func)
