madsen / vbindiff

Visual Binary Diff (VBinDiff) displays files in hex & ASCII and can highlight the differences between 2 files
491 stars 52 forks source link

Prevent segfault when buf index is negative. #4

Closed hexluthor closed 7 years ago

madsen commented 10 years ago

Could you please describe how to reproduce the bug you're trying to fix? How does index get to be negative?

hexluthor commented 10 years ago

It happens with files of similar but different sizes, for example: dd if=/dev/zero of=file1 bs=1 count=208 dd if=/dev/zero of=file2 bs=1 count=210 vbindiff file1 file2

mbouaziz commented 9 years ago

PR#2 seems to be simpler

madsen commented 7 years ago

I've merged #3, which should resolve this issue as well.