Re: [AD] 4.0.2 releasei/CVS |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
> I know what you're referring to, and it's not only a remote problem.
> Technically, it's a "regression" from 4.0.1, but the only reason it
> didn't appear with previous versions is that it would deadlock instead.
Did Allegro always deadlock in that situation previously ? If so, from my
point of view, it is not a regression. Can I make the final release then ?
> What's going on: When you press the close button, an auxiliary thread
> starts the shutdown process (with `exit'). Meanwhile, the main thread
> is still running concurrently, and not expecting the rug to be pulled
> out from under its feet. e.g. it might try writing to `screen', right
> after it is freed, causing a segfault.
That's the big weakness of the default handling of the close button. And the
Windows port has the very same problem.
> Note this won't happen if you hook the close request and shutdown
> gracefully from the main thread. All "real life" programs should be
> doing this anyway... but probably don't. (*ahem*)
I completly agree.
> P.S. I don't think the default handling of close requests by forceful
> killing is right. But that's fodder for post-4.0.2.
I think 6 months of painful experience clearly shows you're right.
--
Eric Botcazou
ebotcazou@xxxxxxxxxx