Subject: Re: bug#78509: Coreutils' mv and cp 9.5 do not work properly on old PPC Mac OS X 10.4.11, Tiger

From: Peter Dyballa <[email-masked]>
Date: Thu, 22 May 2025 11:03:05 +0200

Hello!

Here's a first result, got from using ktrace and kdump – and deleting almost ½ MB of text output:

 17186 mv       CALL  geteuid
 17186 mv       RET   geteuid 501/0x1f5
 17186 mv       CALL  ioctl(0,0x4004667a ,0xbfffd498)
 17186 mv       RET   ioctl 0
 17186 mv       CALL  lstat(0xbfffd875,0xbfffcb28)
 17186 mv       NAMI  "out"
 17186 mv       RET   lstat 0
 17186 mv       CALL  open(0xbfffd875,0x100000,0)
 17186 mv       NAMI  "out"
 17186 mv       RET   open 5
 17186 mv       CALL  open(0x2a1dc,0x100004,0)
 17186 mv       NAMI  "/proc/self/fd"
 17186 mv       RET   open -1 errno 2 No such file or directory
 17186 mv       CALL  stat(0x29410,0xbfffc790)
 17186 mv       NAMI  "."
 17186 mv       RET   stat 0
 17186 mv       CALL  fstat(0x5,0xbfffc7f0)
 17186 mv       RET   fstat 0
 17186 mv       CALL  lstat(0xbfffd873,0xbfffd0e4)
 17186 mv       NAMI  "k"
 17186 mv       RET   lstat 0
 17186 mv       CALL  open(0x29410,0,0)
 17186 mv       NAMI  "."
 17186 mv       RET   open 6
 17186 mv       CALL  fcntl(0x6,0x1,0)
 17186 mv       RET   fcntl 0
 17186 mv       CALL  fcntl(0x6,0x2,0x1)
 17186 mv       RET   fcntl 0
 17186 mv       CALL  fchdir(0x5)
 17186 mv       RET   fchdir -1 errno 20 Not a directory
 17186 mv       CALL  close(0x6)
 17186 mv       RET   close 0

Trying to open on Macs non-existent "/proc/self/fd" could cause a failure state suggesting mv to fchdir into a file, "out"…

--
Mit evolutionären Grüßen

  Pete

"Evolution"            o           __o                     _o _
          °\___o      /0~         -\<,              ^\___ /=\\_/-%
oo~_______ /\ /\______/ \_________O/ O_______________o===>-->O--o____