[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[freetype2] logging 4d68336 05/12: [dlg] Fix compiler warnings.
From: |
Werner LEMBERG |
Subject: |
[freetype2] logging 4d68336 05/12: [dlg] Fix compiler warnings. |
Date: |
Thu, 3 Dec 2020 13:31:35 -0500 (EST) |
branch: logging
commit 4d683362840aa277e00f5905c4a20e306c803710
Author: Werner Lemberg <wl@gnu.org>
Commit: Werner Lemberg <wl@gnu.org>
[dlg] Fix compiler warnings.
* src/dlg/dlgwrap.c: Duplicate some feature test macros from
`dlg.c`, which must come first before loading standard headers. For
example, `freetype.h` loads `stdio.h` if compiled in debug mode.
---
ChangeLog | 8 ++++++++
src/dlg/dlgwrap.c | 5 +++++
2 files changed, 13 insertions(+)
diff --git a/ChangeLog b/ChangeLog
index 62fecac..3f5c081 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
2020-12-01 Werner Lemberg <wl@gnu.org>
+ [dlg] Fix compiler warnings.
+
+ * src/dlg/dlgwrap.c: Duplicate some feature test macros from
+ `dlg.c`, which must come first before loading standard headers. For
+ example, `freetype.h` loads `stdio.h` if compiled in debug mode.
+
+2020-12-01 Werner Lemberg <wl@gnu.org>
+
* src/type42/t42parse.c: Fix `-Wformat` warnings.
2020-12-01 Priyesh Kumar <priyeshkkumar@gmail.com>
diff --git a/src/dlg/dlgwrap.c b/src/dlg/dlgwrap.c
index 0333eb9..ea034fb 100644
--- a/src/dlg/dlgwrap.c
+++ b/src/dlg/dlgwrap.c
@@ -16,6 +16,11 @@
*/
+ /* We have to duplicate these feature test macros from `dlg.c` */
+ /* since `freetype.h` loads some affected standard headers. */
+#define _XOPEN_SOURCE
+#define _POSIX_C_SOURCE 200809L
+
#include <freetype/freetype.h>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [freetype2] logging 4d68336 05/12: [dlg] Fix compiler warnings.,
Werner LEMBERG <=