Skip to content

Conversation

@anthonypapetti
Copy link
Contributor

Fixes #105

This creates protector functions that wrap the functions H5DFOpen() and H5GFOpen in try/catch statements in order to prevent a segmentation fault, and returns -1 on a fault to properly catch it and continue the program gracefully.

@selimnairb
Copy link
Collaborator

@anthonypapetti Sorry it took me so long to get to this. In the future I will trigger builds faster. However, it looks like these changes resulted in a few test cases failing, see here for example. Can you resolve these issues? Thanks.

@anthonypapetti
Copy link
Contributor Author

@anthonypapetti Sorry it took me so long to get to this. In the future I will trigger builds faster. However, it looks like these changes resulted in a few test cases failing, see here for example. Can you resolve these issues? Thanks.

Sounds good, I'll take a look at it. Thanks.

hid_t GopenProtector2(hid_t loc_id, const char *name, hid_t dapl_id) {
hid_t id = -1;
try {
id = H5Dopen2(loc_id, name, dapl_id);
Copy link
Collaborator

Choose a reason for hiding this comment

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

Looks like a copy-paste type here. Should this be calling H5Gopen2 instead of H5Dopen2?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks, fixed that. Probably will not fix tests but it's good to have anyway

@selimnairb selimnairb merged commit f4d7860 into OpenNavigationSurface:master Feb 28, 2025
5 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.

oss-fuzz: Issue 69303: opennavsurf-bag:bag_read_fuzzer: Crash in H5HG__cache_heap_deserialize

2 participants