Serhiy Storchaka added the comment:

The patch for issue3999 was rejected because Python internal state may be 
corrupted when the SIGSEGV signal is raised. This is not the case of this 
issue. gdbm fatal function is called when Python is in consistent state. So we 
free to use any Python C-API. But internal state of concrete GDBM_FILE may be 
corrupted, so we shouldn't use it after handling fatal error. This cause a 
leak, but I think that a leak with an exception is better than just a crash.

May be different type of exception should be raised. May be we need FatalError 
that inherits from BaseException.

Other external libraries used by the stdlib also can crash, and perhaps crashes 
can be converted to exceptions. This issue is only first in the series.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue22035>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to