Skip to content

Conversation

@gcmoreira
Copy link
Contributor

This PR addresses #1438.

Unfortunately, previously the code was messy and difficult to follow. I refactored the _load_segments() function by splitting it based on each dump type, adding docstrings and typing, removing hardcoded values, and cleaning up the code for improved readability and maintainability.

@atcuno Could you please test it thoroughly? It should be fine since I've only rearranged the code.

@gcmoreira gcmoreira requested a review from atcuno December 19, 2024 00:34
@gcmoreira gcmoreira changed the title Windows crashdump fix Windows crashdump fix and refactor Dec 19, 2024
Copy link
Member

@ikelos ikelos left a comment

Choose a reason for hiding this comment

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

Looks good to me, think we can reuse those constants in the crashinfo plugin too... I'll await @atcuno 's review just in case.

SIGNATURE = 0x45474150
VALIDDUMP = 0x504D5544

DUMP_TYPE_FULL = 1
Copy link
Member

Choose a reason for hiding this comment

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

Crash info should probably make use of these constants (at the moment it hardcodes the values).

@gcmoreira
Copy link
Contributor Author

fix: #1438

@ikelos
Copy link
Member

ikelos commented Feb 9, 2025

Waiting on your review please @atcuno (once the parity release is out).

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.

last_bit_seen potential uninitialzed variable usage in crash.py

3 participants