Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
program crashes about 20% of the time
#7
One problem I see in the program is that there's no FREE(anything) in use.  You have multiple places where you _LOADFONT and _LOADIMAGE, but there's no place where you _FREEFONT or _FREEIMAGE.  These are going to create memory leaks where program memory usage keeps going up endlessly, and it'll eventually crash on you after it's ran long enough.

I'd suggest moving those to the start of the program, making them a shared variable, and then just loading them once at start up, so you'd never have to worry about them again. 

(I'm still looking for anything else that stands out, but I thought I'd report as I skim along in the code.)
Reply


Messages In This Thread
RE: program crashes about 20% of the time - by SMcNeill - 12-18-2022, 01:39 AM



Users browsing this thread: 2 Guest(s)