https://git.reactos.org/?p=reactos.git;a=commitdiff;h=9db517f3243018f4861f2…
commit 9db517f3243018f4861f2353d3e60659a39b68d6
Author: Timo Kreuzer <timo.kreuzer(a)reactos.org>
AuthorDate: Tue Nov 12 16:25:30 2024 +0200
Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org>
CommitDate: Wed Jan 22 18:56:08 2025 +0200
[UCRT] Fix definition of _alloca for GCC/Clang
---
sdk/include/ucrt/malloc.h | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/sdk/include/ucrt/malloc.h b/sdk/include/ucrt/malloc.h
index c9e0c24cf19..20abe3fe929 100644
--- a/sdk/include/ucrt/malloc.h
+++ b/sdk/include/ucrt/malloc.h
@@ -50,9 +50,12 @@ typedef struct _heapinfo
#define _mm_malloc(a, b) _aligned_malloc(a, b)
-
+#if defined(__GNUC__) || defined(__clang__)
+#define _alloca(x) __builtin_alloca((x))
+#else
_Ret_notnull_ _Post_writable_byte_size_(_Size)
void* __cdecl _alloca(_In_ size_t _Size);
+#endif