[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] test-canonicalize: avoid a build failure
From: |
Pádraig Brady |
Subject: |
[PATCH] test-canonicalize: avoid a build failure |
Date: |
Tue, 4 Feb 2020 01:04:34 +0000 |
* tests/test-canonicalize.c: Protect the inclusion of null-ptr.h
with the same guard as that used to protect usage of the null_ptr
function, so that one doesn't get a -Werror=unused build failure,
warning about the function being defined but unused.
* tests/test-canonicalize-lgpl.c: Likewise.
---
ChangeLog | 9 +++++++++
tests/test-canonicalize-lgpl.c | 5 ++++-
tests/test-canonicalize.c | 5 ++++-
3 files changed, 17 insertions(+), 2 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 2a86791a8..5e524c56d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2020-02-04 Pádraig Brady <address@hidden>
+
+ test-canonicalize: avoid a build failure
+ * tests/test-canonicalize.c: Protect the inclusion of null-ptr.h
+ with the same guard as that used to protect usage of the null_ptr
+ function, so that one doesn't get a -Werror=unused build failure,
+ warning about the function being defined but unused.
+ * tests/test-canonicalize-lgpl.c: Likewise.
+
2020-02-02 Bruno Haible <address@hidden>
Document the new modules list-c++, set-c++, oset-c++, map-c++, omap-c++.
diff --git a/tests/test-canonicalize-lgpl.c b/tests/test-canonicalize-lgpl.c
index fb49b2047..ff829814e 100644
--- a/tests/test-canonicalize-lgpl.c
+++ b/tests/test-canonicalize-lgpl.c
@@ -39,7 +39,10 @@ SIGNATURE_CHECK (canonicalize_file_name, char *, (const char
*));
#include "same-inode.h"
#include "ignore-value.h"
-#include "null-ptr.h"
+#if GNULIB_defined_canonicalize_file_name
+# include "null-ptr.h"
+#endif
+
#include "macros.h"
#define BASE "t-can-lgpl.tmp"
diff --git a/tests/test-canonicalize.c b/tests/test-canonicalize.c
index 81580c53d..e0b623f19 100644
--- a/tests/test-canonicalize.c
+++ b/tests/test-canonicalize.c
@@ -36,7 +36,10 @@
#include "same-inode.h"
#include "ignore-value.h"
-#include "null-ptr.h"
+#if GNULIB_defined_canonicalize_file_name
+# include "null-ptr.h"
+#endif
+
#include "macros.h"
#define BASE "t-can.tmp"
--
2.24.1
- [PATCH] test-canonicalize: avoid a build failure,
Pádraig Brady <=