Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

Game sometimes crashes upon exit (Developers)

posted by KarlG, 29.05.2022, 15:24

> Since the crash occurs after the "old" interrupt vector has been restored,
> this saved vector most likely has been inadvertently modified.
> star_background is defined as:

...

>
> unsigned char star_background[8000];
>

>
> and accessed:
>
>
> Offset = TempRand&0x1FFF;
> memset(star_background+Offset, Star, 1);
>

>
> The problem is that 0x2000 is 8192, not 8000.

D'oh! Thank you. That explains what I am seeing neatly. It also explains why the issues did not happen every time, since presumably sometimes my random star background routine didn't generate any values > 8000. Thanks again.

 

Complete thread:

Back to the forum
Board view  Mix view
22049 Postings in 2034 Threads, 396 registered users, 210 users online (0 registered, 210 guests)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum