Re: [hatari-devel] Some ACSI images not working in Hatari 2.0

[ Thread Index | Date Index | More Archives ]

David Savinkoff schrieb:

> "Abort trap 6" is searchable on the internet.

"Abort trap 6" seems to point to a bug regarding memory corruption etc.

Recall that Hatari crashes directly after the message "Mounting hard
drive image ...". I see a *confirmed* buffer overflow in
HDC_CheckAndGetSize, which a) is called directly after that message b)
was introduced inbetween Hatari 1.9.0 and 2.0.0.

HDC_CheckAndGetSize calls ...

File_ShrinkName(shortname, filename, sizeof(shortname));

.... however, as you can easily check, File_ShrinkName will reduce long
filenames to a maximal *string* length equal to its last parameter. The
final \0 byte will take another byte in that buffer. So the 'shortname'
buffer overflows for long filenames.

Mail converted by MHonArc 2.6.19+