8000 linux: document and simplify the dso_debug code by schopin-mozilla · Pull Request #221 · rust-minidump/minidump-writer · GitHub
[go: up one dir, main page]

Skip to content

linux: document and simplify the dso_debug code - #221

Merged
marti4d merged 5 commits into
rust-minidump:mainfrom
schopin-mozilla:pod-dso-debug
Aug 26, 2026
Merged

marti4d merged 5 commits into
rust-minidump:mainfrom
schopin-mozilla:pod-dso-debug

Conversation

@schopin-mozilla
Copy link
Copy Markdown
Collaborator

We use the new read_pod to simplify the code.

Split off #195 (sort of)

Do not merge before #220 !!

@schopin-mozilla
schopin-mozilla force-pushed the pod-dso-debug branch 2 times, most recently from 76c1145 to 6252144 Compare August 25, 2026 15:26
@marti4d marti4d left a comment
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Nice! And glad to see you fixed up and added all the comments too :)

@marti4d
marti4d commented Aug 25, 2026
Copy link
Copy Markdown
Collaborator

(As you said -- we should hold off on landing this until #220 is landed)

schopin-mozilla and others added 5 commits August 26, 2026 10:17
If we're going to read it from a crashing process, we can't really trust
its data, which means we can't safely deserialize it into an enum: it's
straight UB to build an enum value outside of its discriminant range.
`goblin::elf::Dyn` is pointer-width agnostic, but the in-memory value is
*not*, which makes that type inappropriate as a basis to copy stuff
over. Since it's the size used for 64-bit targets, it never showed on
those architectures.
This simplifies the code a fair bit.
@marti4d
marti4d merged commit a343da5 into rust-minidump:main Aug 26, 2026
16 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

0