Martinsos / edlib

Lightweight, super fast C/C++ (& Python) library for sequence alignment using edit (Levenshtein) distance.
http://martinsos.github.io/edlib
MIT License
493 stars 162 forks source link

null pointer dereference and segfault in edlibAlign() #75

Closed geeknik closed 7 years ago

geeknik commented 7 years ago

Compiled with afl-clang-fast++ and ASan.

./edlib-aligner -p test025 test025

==11001==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x0000004c7aff bp 0x7ffd61c02190 sp 0x7ffd61c01e00 T0)
    #0 0x4c7afe in edlibAlign /root/edlib/edlib/src/edlib.cpp:158:43
    #1 0x4c011e in main /root/edlib/apps/aligner/aligner.cpp:162:35
    #2 0x7f2795c1ab44 in __libc_start_main /build/glibc-qK83Be/glibc-2.19/csu/libc-start.c:287
    #3 0x4be9bc in _start (/root/edlib/build/bin/edlib-aligner+0x4be9bc)

AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV /root/edlib/edlib/src/edlib.cpp:158 edlibAlign

test025.zip

Martinsos commented 7 years ago

Hm, for some reason I am not able to open your input file! Could you please check what is the reason for that? What are the contents?

Martinsos commented 7 years ago

I can't replicate this one, so I am closing it for now.