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

Malloc size error in rawchunk.c:58:40 #11

Open
seviezhou opened this issue Aug 4, 2020 · 0 comments
Open

Malloc size error in rawchunk.c:58:40 #11

seviezhou opened this issue Aug 4, 2020 · 0 comments

Comments

@seviezhou
Copy link

System info

Ubuntu X64, gcc (Ubuntu 5.5.0-12ubuntu1), iffpp (latest master 0290be4)

Configure

CFLAGS="-g -fsanitize=address" LDFLAGS="-fsanitize=address" ./configure

Command line

./src/iffpp/.libs/lt-iffpp @@

AddressSanitizer output

==59320==WARNING: AddressSanitizer failed to allocate 0xffffffff8000000b bytes
==59320==AddressSanitizer's allocator is terminating the process instead of returning 0
==59320==If you don't like this behavior set allocator_may_return_null=1
==59320==AddressSanitizer CHECK failed: /home/seviezhou/llvm-6.0.0/projects/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc:225 "((0)) != (0)" (0x0, 0x0)
    #0 0x4e7b7f in __asan::AsanCheckFailed(char const*, int, char const*, unsigned long long, unsigned long long) /home/seviezhou/llvm-6.0.0/projects/compiler-rt/lib/asan/asan_rtl.cc:69
    #1 0x504af5 in __sanitizer::CheckFailed(char const*, int, char const*, unsigned long long, unsigned long long) /home/seviezhou/llvm-6.0.0/projects/compiler-rt/lib/sanitizer_common/sanitizer_termination.cc:79
    #2 0x4ed9a6 in __sanitizer::ReportAllocatorCannotReturnNull() /home/seviezhou/llvm-6.0.0/projects/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc:225
    #3 0x4ed9e3 in __sanitizer::ReturnNullOrDieOnFailure::OnBadRequest() /home/seviezhou/llvm-6.0.0/projects/compiler-rt/lib/sanitizer_common/sanitizer_allocator.cc:241
    #4 0x41eab6 in __asan::asan_malloc(unsigned long, __sanitizer::BufferedStackTrace*) /home/seviezhou/llvm-6.0.0/projects/compiler-rt/lib/asan/asan_allocator.cc:856
    #5 0x4de664 in __interceptor_malloc /home/seviezhou/llvm-6.0.0/projects/compiler-rt/lib/asan/asan_malloc_linux.cc:89
    #6 0x7f419ec53f23 in IFF_readRawChunk /home/seviezhou/libiff/src/libiff/rawchunk.c:58:40
    #7 0x7f419ec47a22 in IFF_readChunk /home/seviezhou/libiff/src/libiff/chunk.c:76:25
    #8 0x7f419ec4b295 in IFF_readGroup /home/seviezhou/libiff/src/libiff/group.c:80:21
    #9 0x7f419ec4e754 in IFF_readForm /home/seviezhou/libiff/src/libiff/form.c:45:23
    #10 0x7f419ec47856 in IFF_readChunk /home/seviezhou/libiff/src/libiff/chunk.c:64:21
    #11 0x7f419ec558f3 in IFF_readFd /home/seviezhou/libiff/src/libiff/iff.c:35:13
    #12 0x7f419ec55b48 in IFF_read /home/seviezhou/libiff/src/libiff/iff.c:65:13
    #13 0x5167b3 in IFF_prettyPrint /home/seviezhou/libiff/src/iffpp/pp.c:33:10
    #14 0x516477 in main /home/seviezhou/libiff/src/iffpp/main.c:137:12
    #15 0x7f419dd4983f in __libc_start_main /build/glibc-e6zv40/glibc-2.23/csu/../csu/libc-start.c:291
    #16 0x41a478 in _start (/home/seviezhou/libiff/src/iffpp/.libs/lt-iffpp+0x41a478)

POC

malloc-size-error-IFF_readRawChunk-rawchunk-58.zip

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

No branches or pull requests

1 participant