-
-
Notifications
You must be signed in to change notification settings - Fork 265
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix issues with empty or uninitialized link names #4322
Conversation
Converts an assertion in H5G_loc_find into a normal error check that checks for empty link names Initializes H5O_link_t structure early in H5G__ent_to_link to avoid trying to free potentially uninitialized memory Checks for an empty link name after H5MM_strndup in H5G__ent_to_link Fixes GitHub HDFGroup#4307
@@ -410,9 +410,12 @@ H5G_loc_find(const H5G_loc_t *loc, const char *name, H5G_loc_t *obj_loc /*out*/) | |||
|
|||
/* Check args. */ | |||
assert(loc); | |||
assert(name && *name); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was failing in debug builds due to the assertion on *name
, but would pass for release/production builds. That said, I don't think it's allowed to have an empty link name for an object, so I converted this to a regular error check.
This fixes the current CVE testing. It doesn't appear to be a missed issue, but rather a new issue that was masked by previous CVE problems. |
Converts an assertion in H5G_loc_find into a normal error check that checks for empty link names Initializes H5O_link_t structure early in H5G__ent_to_link to avoid trying to free potentially uninitialized memory Checks for an empty link name after H5MM_strndup in H5G__ent_to_link Fixes GitHub HDFGroup#4307
* Remove VS ptable error from Known Problems (#4317) * Simply check for datatypes with unusual number of unused bits (#4309) Avoids potential undefined behavior in H5T_is_numeric_with_unusual_unused_bits * Fix issues with empty or uninitialized link names (#4322) Converts an assertion in H5G_loc_find into a normal error check that checks for empty link names Initializes H5O_link_t structure early in H5G__ent_to_link to avoid trying to free potentially uninitialized memory Checks for an empty link name after H5MM_strndup in H5G__ent_to_link Fixes GitHub #4307 * Fix h5py testing failure due to invalid datatype IDs (#4321) Fixes an issue where invalid datatype IDs are passed to application conversion functions in the case where the top-level conversion function is a library-internal function that operates on a container-like datatype, but one or more of the base datatype members are converted with an application conversion function. * Revise _Float16 configure checks (#4323) Run configure checks with and without CFLAGS/CMAKE_C_FLAGS since some compilers work in one case while not working in the other case Sync CMake configure checks with Autotools
* Remove VS ptable error from Known Problems (HDFGroup#4317) * Simply check for datatypes with unusual number of unused bits (HDFGroup#4309) Avoids potential undefined behavior in H5T_is_numeric_with_unusual_unused_bits * Fix issues with empty or uninitialized link names (HDFGroup#4322) Converts an assertion in H5G_loc_find into a normal error check that checks for empty link names Initializes H5O_link_t structure early in H5G__ent_to_link to avoid trying to free potentially uninitialized memory Checks for an empty link name after H5MM_strndup in H5G__ent_to_link Fixes GitHub HDFGroup#4307 * Fix h5py testing failure due to invalid datatype IDs (HDFGroup#4321) Fixes an issue where invalid datatype IDs are passed to application conversion functions in the case where the top-level conversion function is a library-internal function that operates on a container-like datatype, but one or more of the base datatype members are converted with an application conversion function. * Revise _Float16 configure checks (HDFGroup#4323) Run configure checks with and without CFLAGS/CMAKE_C_FLAGS since some compilers work in one case while not working in the other case Sync CMake configure checks with Autotools
Converts an assertion in H5G_loc_find into a normal error check that checks for empty link names Initializes H5O_link_t structure early in H5G__ent_to_link to avoid trying to free potentially uninitialized memory Checks for an empty link name after H5MM_strndup in H5G__ent_to_link Fixes GitHub HDFGroup#4307
Converts an assertion in H5G_loc_find into a normal error check that checks for empty link names
Initializes H5O_link_t structure early in H5G__ent_to_link to avoid trying to free potentially uninitialized memory
Checks for an empty link name after H5MM_strndup in H5G__ent_to_link
Fixes GitHub #4307