Skip to content

darwin: Restore pipe file metadata - #395

Merged
jiegec merged 4 commits into
lsof-org:masterfrom
hja-oss:fix/darwin-pipe-file-info
Nov 17, 2026
Merged

jiegec merged 4 commits into
lsof-org:masterfrom
hja-oss:fix/darwin-pipe-file-info

Conversation

@hja-oss

@hja-oss hja-oss commented Nov 15, 2026

Copy link
Copy Markdown
Contributor

Populate pipe access modes, offsets, and flags using the existing file-info helper, including pipe-backed Mach fileports. Extend LTbasic2 with a small regression check for pipe access modes.

@hja-oss

hja-oss commented Nov 15, 2026

Copy link
Copy Markdown
Contributor Author

OpenBSD:

  FAIL: tests/LTbasic2
  ====================
  
  ERROR!!!  pipe access modes missing or incorrect.
  Testing round 0
  FAIL tests/LTbasic2 (exit status: 1)

So OpenBSD doesn’t report DTYPE_PIPE descriptors at all, no pipe entries, no access modes, nothing to validate. The test therefore saw pipes_found == 0 and failed.

Comment thread tests/LTbasic2.c Outdated
fd = -1;
pipes_found = 0;
pipes_seen = 0;
if (pipe(pipefd)) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create pipe only once before loop?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

makes sense, the pipe is recreated on every round for no reason!

@hja-oss hja-oss changed the title [darwin] Restore pipe file metadata darwin: Restore pipe file metadata Nov 16, 2026
@jiegec
jiegec merged commit 23cf420 into lsof-org:master Nov 17, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants