Skip to content
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

ASAN fix for test_ld - free sub-allocation of fields #1052

Merged
merged 1 commit into from
Oct 1, 2021
Merged

ASAN fix for test_ld - free sub-allocation of fields #1052

merged 1 commit into from
Oct 1, 2021

Conversation

byrnHDF
Copy link
Contributor

@byrnHDF byrnHDF commented Sep 29, 2021

Dynamic Analysis indicated an error when creating a table of field names, an invalid field would delete the memb allocation but not the memb->names allocation.

@byrnHDF
Copy link
Contributor Author

byrnHDF commented Sep 29, 2021

Dynamic Analysis output for test: HL_test_ld

==1032389==ERROR: LeakSanitizer: detected memory leaks

Direct leak Direct leak of 88 byte(s) in 1 object(s) allocated from:
#0 0x496662 in calloc (/home/hdf-winadmin/autotest/hdf5trunk-StdClang-code-ubuntu2010/build/ctest/clang/Address/bin/hl_test_ld+0x496662)
#1 0x7fd224b8a337 in H5LD_construct_vector (/home/hdf-winadmin/autotest/hdf5trunk-StdClang-code-ubuntu2010/build/ctest/clang/Address/bin/libhdf5_hl.so.1000+0x2e337)
#2 0x7fd224b8b199 in H5LD_get_dset_type_size (/home/hdf-winadmin/autotest/hdf5trunk-StdClang-code-ubuntu2010/build/ctest/clang/Address/bin/libhdf5_hl.so.1000+0x2f199)
#3 0x4cb6b4 in test_LD_size (/home/hdf-winadmin/autotest/hdf5trunk-StdClang-code-ubuntu2010/build/ctest/clang/Address/bin/hl_test_ld+0x4cb6b4)
#4 0x4c7d0a in main (/home/hdf-winadmin/autotest/hdf5trunk-StdClang-code-ubuntu2010/build/ctest/clang/Address/bin/hl_test_ld+0x4c7d0a)
#5 0x7fd22397fcb1 in __libc_start_main csu/../csu/libc-start.c:314:16

@byrnHDF byrnHDF mentioned this pull request Sep 30, 2021
@lrknox lrknox merged commit b3cb56e into HDFGroup:develop Oct 1, 2021
lrknox pushed a commit that referenced this pull request Oct 6, 2021
* Merge ASAN fixes

Fix ASAN issue in h5dump error path #1051
ASAN fix for test_ld - free sub-allocation of fields #1052

* Merge Rework error allocation free.
@byrnHDF byrnHDF deleted the develop-dyan-ld-test branch November 1, 2021 13:05
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.

3 participants