mirror of
https://github.com/micropython/micropython.git
synced 2026-01-05 03:30:14 +01:00
py/gc: Only use no_sanitize_address attribute for GCC 4.8 and above.
It's not supported on older GCC versions. Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
2
py/gc.c
2
py/gc.c
@@ -345,7 +345,7 @@ void gc_collect_start(void) {
|
||||
// Address sanitizer needs to know that the access to ptrs[i] must always be
|
||||
// considered OK, even if it's a load from an address that would normally be
|
||||
// prohibited (due to being undefined, in a red zone, etc).
|
||||
#ifdef __GNUC__
|
||||
#if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 8))
|
||||
__attribute__((no_sanitize_address))
|
||||
#endif
|
||||
static void *gc_get_ptr(void **ptrs, int i) {
|
||||
|
||||
Reference in New Issue
Block a user