Bug 507720 - Review syscalls returning file descriptors (other platforms)
Summary: Review syscalls returning file descriptors (other platforms)
Status: RESOLVED FIXED
Alias: None
Product: valgrind
Classification: Developer tools
Component: general (other bugs)
Version First Reported In: 3.25 GIT
Platform: Other Other
: NOR normal
Target Milestone: ---
Assignee: Paul Floyd
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-08-01 05:26 UTC by Paul Floyd
Modified: 2025-08-24 19:35 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Floyd 2025-08-01 05:26:31 UTC
See https://bugs.kde.org/show_bug.cgi?id=493430
Comment 1 Paul Floyd 2025-08-20 20:03:16 UTC
Not just returning fds, also just using them.
Comment 2 Paul Floyd 2025-08-23 10:49:01 UTC
Hopefully mostly done for FreeBSD.
commit b1f204f636746be3a9042cc3eb8355d51dfb051b (HEAD -> master, origin/master, origin/HEAD)
Author: Paul Floyd <pjfloyd@wanadoo.fr>
Date:   Sat Aug 23 12:42:24 2025 +0200

    FreeBSD syscalls: fd handling (part 1)
    
    For
    Bug 507720 - Review syscalls returning file descriptors (other platforms)
    
    Some more recording of fd opens and closes
    Lots of checks for the directory fd of *at() syscalls
    Fixed a few bugs in pdfork and pdkill (and updated the testcase).
    Updated a few message strings.
    Started improving readlinkat - needs more work.


illumos next.
Comment 3 Paul Floyd 2025-08-24 19:35:14 UTC
More commits:

commit 52dddd460b0778f862c062c82d8d2819f740c268
Author: Paul Floyd <pjfloyd@wanadoo.fr>
Date:   Sat Aug 23 14:19:33 2025 +0200

    FreeBSD syscalls: fd handling (part 2)
    
    amd64 and x86 files

commit 4a420cccbea43c2458d0181270f31efdc30eb52a
Author: Paul Floyd <pjfloyd@wanadoo.fr>
Date:   Sat Aug 23 15:42:47 2025 +0200

    FreeBSD syscalls: fd handling (part 3)
    
    arm64 file

commit a139ed0b3c0af09bf0bcc698072225eb4021a920
Author: Paul Floyd <pjfloyd@wanadoo.fr>
Date:   Sun Aug 24 11:25:51 2025 +0200

    illumos syscalls: fd handling (part 4)
    
    Almost everything looked OK. Added a couple of POST_newFd_RES
    macro uses.
    
    There are a few functions that create fds other than via RES
    (like pipe). For these I think that we need to add a
    POST_newFd(fd) macro, plus in a few places refactor so that
    RES is available to set the status after ML_(get_next_new_fd).

commit 5deb5b45d10bf6f431bc7119aa184636cd802abf
Author: Paul Floyd <pjfloyd@wanadoo.fr>
Date:   Sun Aug 24 16:16:24 2025 +0200

    Darwin syscalls: fd handling (part 4)
    
    Most already done.

(the above should have been part 5).