v7-0002-Fixup-fix-compiler-warnings-if-LC_C_LOCALE-exists.patch

text/plain

Filename: v7-0002-Fixup-fix-compiler-warnings-if-LC_C_LOCALE-exists.patch
Type: text/plain
Part: 1
Message: Re: On non-Windows, hard depend on uselocale(3)

Patch

Same data as JSON: GET /api/v1/attachments/:id/patch the parsed metadata as JSON — format, series position, per-file stats; never the diff bytes. API reference →
Format: format-patch
Series: patch v7-0002
Subject: Fixup: fix compiler warnings if LC_C_LOCALE exists
File+
src/port/locale.c 4 0
From d61d358997ce6c15a891588953b76e174e3041ac Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Sun, 9 Feb 2025 07:49:00 +0100
Subject: [PATCH v7 2/3] Fixup: fix compiler warnings if LC_C_LOCALE exists

---
 src/port/locale.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/port/locale.c b/src/port/locale.c
index 387fb4a107a..b3d48628915 100644
--- a/src/port/locale.c
+++ b/src/port/locale.c
@@ -16,6 +16,8 @@
 
 #include "c.h"
 
+#ifndef LC_C_LOCALE
+
 #ifndef WIN32
 #include <pthread.h>
 #else
@@ -78,3 +80,5 @@ pg_get_c_locale(void)
 
 	return c_locale;
 }
+
+#endif							/* not LC_C_LOCALE */
-- 
2.48.1