Fixed a bug from the previous commit and changed some fseek's in ide.c to fseeko64.

This commit is contained in:
OBattler
2017-01-05 19:48:51 +01:00
parent 3972503a8e
commit 6349953413
2 changed files with 3 additions and 3 deletions

View File

@@ -388,7 +388,7 @@ static uint32_t iso_size()
iso_size >>= 11;
fclose(iso_image);
return (uint32_t) (iso_size - 1);
return (uint32_t) (iso_size);
}
static int iso_status()

View File

@@ -503,9 +503,9 @@ static void loadhd(IDE *ide, int d, const char *fn)
{
if (image_is_hdi(fn))
{
fseek(ide->hdfile, 0x8, SEEK_SET);
fseeko64(ide->hdfile, 0x8, SEEK_SET);
fread(&(ide->base), 1, 4, ide->hdfile);
fseek(ide->hdfile, 0x10, SEEK_SET);
fseeko64(ide->hdfile, 0x10, SEEK_SET);
fread(&sector_size, 1, 4, ide->hdfile);
if (sector_size != 512)
{