Allegro.cc - Online Community

Allegro.cc Forums » Programming Questions » Allegro executable won't close completely on Windows 10

This thread is locked; no one can reply to it. rss feed Print
Allegro executable won't close completely on Windows 10
Frank Drebin
Member #2,987
December 2002
avatar

Hi guys,

when I run Brutalo Deluxe, close it and then try to delete or move the executable I get an error message saying that the file is still in use and the action cannot be performed. Indeed the binary still shows up in the task manager even though the window closed and the game was shut down properly. This only happens on Windows 10 and not on Windows 7.

Do you have any clue? ???

LennyLen
Member #5,313
December 2004
avatar

I don't have a clue, but I'd suggest cutting down your code until you have a minimal example that exhibits the behaviour. Since this isn't a common problem, the cause is something unique to your program.

Edgar Reynaldo
Member #8,592
May 2007
avatar

Frank Drebin
Member #2,987
December 2002
avatar

Thanks for your hints! Putting allegro_exit() at the end of the main function seems to solve the problem!!! Also, I could track down the line of code causing this issue: it seems to be the call set_color_depth(32) before setting the graphics mode (trying windowed mode first and then fullscreen mode).

However, I'm still wondering what't the root cause ...

Go to: