mirror of
git://anongit.mindrot.org/openssh.git
synced 2025-01-09 02:59:30 +00:00
prefer ln to cp for temporary copy of sshd
I saw failures on the reexec fallback test on Darwin 19.4 where fork()ed children of a process that had it's executable removed would instantly fail. Using ln to preserve the inode avoids this.
This commit is contained in:
parent
f700d316c6
commit
3ab6fccc39
@ -9,7 +9,10 @@ SSHD_COPY=$OBJ/sshd
|
|||||||
# Start a sshd and then delete it
|
# Start a sshd and then delete it
|
||||||
start_sshd_copy ()
|
start_sshd_copy ()
|
||||||
{
|
{
|
||||||
cp $SSHD_ORIG $SSHD_COPY
|
# NB. prefer ln to cp here. On some OSX 19.4 configurations,
|
||||||
|
# djm has seen failure after fork() when the executable image
|
||||||
|
# has been removed from the filesystem.
|
||||||
|
ln $SSHD_ORIG $SSHD_COPY || cp $SSHD_ORIG $SSHD_COPY
|
||||||
SSHD=$SSHD_COPY
|
SSHD=$SSHD_COPY
|
||||||
start_sshd
|
start_sshd
|
||||||
SSHD=$SSHD_ORIG
|
SSHD=$SSHD_ORIG
|
||||||
|
Loading…
Reference in New Issue
Block a user