gimp/gimp-configure-c99.patch

57 lines
1.4 KiB
Diff
Raw Normal View History

Do not call the undeclared exit function. Implicit function
declarations are likely not going to be supported by future compilers
by default, changing the outcome of this configure probe.
Submitted upstream: <https://gitlab.gnome.org/GNOME/gimp/-/merge_requests/810>
diff --git a/configure b/configure
index 6e62da8e3c164f82..f1c447baf7ff68f7 100755
--- a/configure
+++ b/configure
@@ -28898,17 +28898,17 @@ else $as_nop
char *shmaddr;
id = shmget (IPC_PRIVATE, 4, IPC_CREAT | 0600);
if (id == -1)
- exit (2);
+ return 2;
shmaddr = shmat (id, 0, 0);
shmctl (id, IPC_RMID, 0);
if ((char*) shmat (id, 0, 0) == (char*) -1)
{
shmdt (shmaddr);
- exit (1);
+ return 1;
}
shmdt (shmaddr);
shmdt (shmaddr);
- exit (0);
+ return 0;
}
_ACEOF
diff --git a/configure.ac b/configure.ac
index d73f56228712f59d..32d2a072863ae64f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1284,17 +1284,17 @@ elif test "x$shmtype" = "xsysv"; then
char *shmaddr;
id = shmget (IPC_PRIVATE, 4, IPC_CREAT | 0600);
if (id == -1)
- exit (2);
+ return 2;
shmaddr = shmat (id, 0, 0);
shmctl (id, IPC_RMID, 0);
if ((char*) shmat (id, 0, 0) == (char*) -1)
{
shmdt (shmaddr);
- exit (1);
+ return 1;
}
shmdt (shmaddr);
shmdt (shmaddr);
- exit (0);
+ return 0;
}
]])],
[AC_DEFINE([IPC_RMID_DEFERRED_RELEASE],[1],