From: Elvira Khabirova Date: Sun, 5 Jun 2016 23:39:59 +0000 (+0300) Subject: tests/ptrace.c: fix fork() return value check X-Git-Tag: v4.13~175 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f6be7ae12c2b1a1bc4bfcd8cc77508f6eac8914a;p=strace tests/ptrace.c: fix fork() return value check * tests/ptrace.c (test_peeksiginfo): Explicitly cast fork() return value to pid_t. --- diff --git a/tests/ptrace.c b/tests/ptrace.c index 2fbefdd4..7971b894 100644 --- a/tests/ptrace.c +++ b/tests/ptrace.c @@ -72,7 +72,7 @@ test_peeksiginfo(unsigned long pid, const unsigned long bad_request) (unsigned) pid, psi->off, psi->nr, bad_request, rc, errno2name()); pid = fork(); - if (pid < 0) + if ((pid_t) pid < 0) perror_msg_and_fail("fork"); if (!pid) {