SDL_image: IMG_png.c: fix build (SAVE_PNG <-> SDL_IMAGE_SAVE_PNG confusion)

From 9d71d2ace4123a4a52768269adaa7f6a21cb5cd0 Mon Sep 17 00:00:00 2001
From: Ozkan Sezer <[EMAIL REDACTED]>
Date: Tue, 10 May 2022 21:33:10 +0300
Subject: [PATCH] IMG_png.c: fix build (SAVE_PNG <-> SDL_IMAGE_SAVE_PNG
 confusion)

---
 IMG_png.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/IMG_png.c b/IMG_png.c
index 1ba1c8e..d93ec66 100644
--- a/IMG_png.c
+++ b/IMG_png.c
@@ -23,7 +23,6 @@
 
 #include "SDL_image.h"
 
-
 /* We'll have PNG save support by default */
 #ifndef SAVE_PNG
 #define SAVE_PNG    1
@@ -116,7 +115,7 @@ static struct {
     jmp_buf* (*png_set_longjmp_fn) (png_structrp, png_longjmp_ptr, size_t);
 #endif
 #endif
-#if SDL_IMAGE_SAVE_PNG
+#if SAVE_PNG
     png_structp (*png_create_write_struct) (png_const_charp user_png_ver, png_voidp error_ptr, png_error_ptr error_fn, png_error_ptr warn_fn);
     void (*png_destroy_write_struct) (png_structpp png_ptr_ptr, png_infopp info_ptr_ptr);
     void (*png_set_write_fn) (png_structrp png_ptr, png_voidp io_ptr, png_rw_ptr write_data_fn, png_flush_ptr output_flush_fn);
@@ -171,7 +170,7 @@ int IMG_InitPNG()
         FUNCTION_LOADER(png_set_longjmp_fn, jmp_buf* (*) (png_structrp, png_longjmp_ptr, size_t))
 #endif
 #endif
-#if SDL_IMAGE_SAVE_PNG
+#if SAVE_PNG
         FUNCTION_LOADER(png_create_write_struct, png_structp (*) (png_const_charp user_png_ver, png_voidp error_ptr, png_error_ptr error_fn, png_error_ptr warn_fn))
         FUNCTION_LOADER(png_destroy_write_struct, void (*) (png_structpp png_ptr_ptr, png_infopp info_ptr_ptr))
         FUNCTION_LOADER(png_set_write_fn, void (*) (png_structrp png_ptr, png_voidp io_ptr, png_rw_ptr write_data_fn, png_flush_ptr output_flush_fn))