Added a sanity check to the video code.
This commit is contained in:
@@ -910,7 +910,7 @@ void
|
|||||||
loadfont(wchar_t *s, int format)
|
loadfont(wchar_t *s, int format)
|
||||||
{
|
{
|
||||||
FILE *f;
|
FILE *f;
|
||||||
int c,d;
|
int c, d;
|
||||||
|
|
||||||
f = rom_fopen(s, L"rb");
|
f = rom_fopen(s, L"rb");
|
||||||
if (f == NULL)
|
if (f == NULL)
|
||||||
@@ -1013,8 +1013,10 @@ loadfont(wchar_t *s, int format)
|
|||||||
fseek(f, 8, SEEK_CUR);
|
fseek(f, 8, SEEK_CUR);
|
||||||
}
|
}
|
||||||
/* The second 4k holds an 8x16 font */
|
/* The second 4k holds an 8x16 font */
|
||||||
for (c = 0; c < 256; c++)
|
for (c = 0; c < 256; c++) {
|
||||||
fread(&fontdatm[c][0], 1, 16, f);
|
if (fread(&fontdatm[c][0], 1, 16, f) != 16)
|
||||||
|
fatal("loadfont(): Error reading font file in Sigma Coloar 400 mdoe, c = %i\n", c);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 8: /* Amstrad PC1512, Toshiba T1000/T1200 */
|
case 8: /* Amstrad PC1512, Toshiba T1000/T1200 */
|
||||||
|
Reference in New Issue
Block a user