From 1cdf374314cfb788cd9059aa2cff8281cb745c91 Mon Sep 17 00:00:00 2001 From: Sergey Fedorov Date: Wed, 14 Aug 2024 16:07:26 +0800 Subject: [PATCH] IMG_*: fix remaining cases of incorrect attribute placement (cherry picked from commit 5c5051cb3e594cf301e76f6e6b55df1c6b54c04b) --- src/IMG_avif.c | 2 +- src/IMG_jxl.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/IMG_avif.c b/src/IMG_avif.c index 31217310..95c0da54 100644 --- a/src/IMG_avif.c +++ b/src/IMG_avif.c @@ -52,11 +52,11 @@ static struct { if (lib.FUNC == NULL) { IMG_SetError("Missing avif.framework"); return -1; } #endif -int IMG_InitAVIF() #ifdef __APPLE__ /* Need to turn off optimizations so weak framework load check works */ __attribute__ ((optnone)) #endif +int IMG_InitAVIF() { if ( lib.loaded == 0 ) { #ifdef LOAD_AVIF_DYNAMIC diff --git a/src/IMG_jxl.c b/src/IMG_jxl.c index ace1ea17..d59edd40 100644 --- a/src/IMG_jxl.c +++ b/src/IMG_jxl.c @@ -51,11 +51,11 @@ static struct { if (lib.FUNC == NULL) { IMG_SetError("Missing jxl.framework"); return -1; } #endif -int IMG_InitJXL() #ifdef __APPLE__ /* Need to turn off optimizations so weak framework load check works */ __attribute__ ((optnone)) #endif +int IMG_InitJXL() { if ( lib.loaded == 0 ) { #ifdef LOAD_JXL_DYNAMIC