[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 1/3] execute-tests: pacify compiler
From: |
Paul Eggert |
Subject: |
[PATCH 1/3] execute-tests: pacify compiler |
Date: |
Wed, 21 Apr 2021 11:11:48 -0700 |
* tests/test-execute-main.c (main): Use 0x7DEADBEE rather than
0xDEADBEEF for nonces, to avoid provoking AIX XLC compiler warning
that the latter is out of int range.
---
ChangeLog | 7 +++++++
tests/test-execute-main.c | 6 +++---
2 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index d2ea4e509..3aaee32bf 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2021-04-21 Paul Eggert <eggert@cs.ucla.edu>
+
+ execute-tests: pacify compiler
+ * tests/test-execute-main.c (main): Use 0x7DEADBEE rather than
+ 0xDEADBEEF for nonces, to avoid provoking AIX XLC compiler warning
+ that the latter is out of int range.
+
2021-04-20 Paul Eggert <eggert@cs.ucla.edu>
malloc-gnu-tests, etc.: use volatile for clang
diff --git a/tests/test-execute-main.c b/tests/test-execute-main.c
index 944dcd1ee..a6a9fe406 100644
--- a/tests/test-execute-main.c
+++ b/tests/test-execute-main.c
@@ -132,7 +132,7 @@ main (int argc, char *argv[])
{
/* Check SIGPIPE handling with ignore_sigpipe = false. */
const char *prog_argv[3] = { prog_path, "3", NULL };
- int termsig = 0xDEADBEEF;
+ int termsig = 0x7DEADBEE;
int ret = execute (progname, prog_argv[0], prog_argv, NULL,
false, false, false, false, true, false, &termsig);
ASSERT (ret == 127);
@@ -145,7 +145,7 @@ main (int argc, char *argv[])
{
/* Check SIGPIPE handling with ignore_sigpipe = true. */
const char *prog_argv[3] = { prog_path, "4", NULL };
- int termsig = 0xDEADBEEF;
+ int termsig = 0x7DEADBEE;
int ret = execute (progname, prog_argv[0], prog_argv, NULL,
true, false, false, false, true, false, &termsig);
ASSERT (ret == 0);
@@ -157,7 +157,7 @@ main (int argc, char *argv[])
{
/* Check other signal. */
const char *prog_argv[3] = { prog_path, "5", NULL };
- int termsig = 0xDEADBEEF;
+ int termsig = 0x7DEADBEE;
int ret = execute (progname, prog_argv[0], prog_argv, NULL,
false, false, false, false, true, false, &termsig);
ASSERT (ret == 127);
--
2.27.0
- [PATCH 1/3] execute-tests: pacify compiler,
Paul Eggert <=