mirror of
https://github.com/containers/podman.git
synced 2025-05-17 06:59:07 +08:00
rootless: fix hang on s390x
avoid using the glibc fork() function after using directly the clone() syscall, as it confuses glibc causing the fork() to hang in some cases. The issue has been observed only on s390x, and the fix was confirmed in the issue discussion. Closes: https://github.com/containers/podman/issues/25184 Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
@ -658,7 +658,7 @@ create_pause_process (const char *pause_pid_file_path, char **argv)
|
||||
if (pipe (p) < 0)
|
||||
return -1;
|
||||
|
||||
pid = fork ();
|
||||
pid = syscall_clone (SIGCHLD, NULL);
|
||||
if (pid < 0)
|
||||
{
|
||||
close (p[0]);
|
||||
@ -689,7 +689,7 @@ create_pause_process (const char *pause_pid_file_path, char **argv)
|
||||
close (p[0]);
|
||||
|
||||
setsid ();
|
||||
pid = fork ();
|
||||
pid = syscall_clone (SIGCHLD, NULL);
|
||||
if (pid < 0)
|
||||
_exit (EXIT_FAILURE);
|
||||
|
||||
|
Reference in New Issue
Block a user