diff options
author | Nikita Popov <nikita.ppv@gmail.com> | 2020-10-05 10:46:46 +0200 |
---|---|---|
committer | Nikita Popov <nikita.ppv@gmail.com> | 2020-10-05 10:46:46 +0200 |
commit | 9ad5381a2f94073f2d84bdda9bc8892d18587fdd (patch) | |
tree | 083657dc3332e7c14ccf949d964037fd1cc3d532 /build | |
parent | c00816a38fe762777ca0b7dd3035406b51a921b1 (diff) | |
parent | aa405b7da270595d349d0596ad31305a41d4b1c0 (diff) | |
download | php-git-9ad5381a2f94073f2d84bdda9bc8892d18587fdd.tar.gz |
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fix -Wimplicit-function-declaration in configure
Diffstat (limited to 'build')
-rw-r--r-- | build/php.m4 | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/build/php.m4 b/build/php.m4 index 0205d01c3b..bc5286b36d 100644 --- a/build/php.m4 +++ b/build/php.m4 @@ -1176,14 +1176,14 @@ AC_DEFUN([PHP_DOES_PWRITE_WORK],[ #include <unistd.h> #include <errno.h> $1 - main() { + int main() { int fd = open("conftest_in", O_WRONLY|O_CREAT, 0600); - if (fd < 0) exit(1); - if (pwrite(fd, "text", 4, 0) != 4) exit(1); + if (fd < 0) return 1; + if (pwrite(fd, "text", 4, 0) != 4) return 1; /* Linux glibc breakage until 2.2.5 */ - if (pwrite(fd, "text", 4, -1) != -1 || errno != EINVAL) exit(1); - exit(0); + if (pwrite(fd, "text", 4, -1) != -1 || errno != EINVAL) return 1; + return 0; } ]])],[ @@ -1209,14 +1209,14 @@ AC_DEFUN([PHP_DOES_PREAD_WORK],[ #include <unistd.h> #include <errno.h> $1 - main() { + int main() { char buf[3]; int fd = open("conftest_in", O_RDONLY); - if (fd < 0) exit(1); - if (pread(fd, buf, 2, 0) != 2) exit(1); + if (fd < 0) return 1; + if (pread(fd, buf, 2, 0) != 2) return 1; /* Linux glibc breakage until 2.2.5 */ - if (pread(fd, buf, 2, -1) != -1 || errno != EINVAL) exit(1); - exit(0); + if (pread(fd, buf, 2, -1) != -1 || errno != EINVAL) return 1; + return 0; } ]])],[ ac_cv_pread=yes @@ -1478,13 +1478,13 @@ int seeker(void *cookie, off64_t *position, int whence) cookie_io_functions_t funcs = {reader, writer, seeker, closer}; -main() { +int main() { struct cookiedata g = { 0 }; FILE *fp = fopencookie(&g, "r", funcs); if (fp && fseek(fp, 8192, SEEK_SET) == 0 && g.pos == 8192) - exit(0); - exit(1); + return 0; + return 1; } ]])], [ |