Re: [hatari-devel] Statistician app NULL pointer crash with GEMDOS HD emu? |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
Am Sun, 24 Aug 2014 13:49:10 +0300
schrieb Eero Tamminen <oak@xxxxxxxxxxxxxx>:
> Hi,
>
> On sunnuntai 24 elokuu 2014, Thomas Huth wrote:
> > schrieb "Konador, Cyprian" <cyprian.konador@xxxxxx>:
> > > > -----Original Message-----
> > > > From: Eero Tamminen
> > > > Sent: Friday, August 22, 2014 9:38 PM
> > > >
> > > > Could somebody more knowledgeable with ASM look into why
> > > > Statistician application:
> > > > http://www.umich.edu/~archive/atari/Utilities/Benchmark/stats.lzh
> > > >
> > > > Crashes right after doing Dfree() call with Hatari GEMDOS HD
> > > > emulation, when you click on a (GEMDOS HD emu) drive name
> > > > button.
>
> FYI: It crashes also if one clicks onto an active floppy drive
> which doesn't have a disk image inserted. In this case TOS
> returns -1 from Dfree() in D0 and DISKINFO struct contents are
> zeroes (i.e. this is different from GEMDOS HD emu case), so I
> guess the program doesn't check error code properly.
Ok, I now had a look at this program, and indeed, it seems to lack some
proper error code checking. However, as far as I can see, the problem
is not Dfree, but the BIOS function GetBPB (BIOS #7). It returns zero
for our GEMDOS drive (and certainly also for empty floppy drives). The
stats program does not check for zero here and simply assumes the
pointer is valid --> crash.
Thomas