New submission from Serhiy Storchaka: It is possible to crash Python by breaking opened gdbm database.
>>> import _gdbm as dbm >>> db = dbm.open('x.db', 'n') >>> open('x.db', 'wb').close() >>> db[b'a'] = b'b' gdbm fatal: read error Proposed patch tries to convert fatal gdbm into regular exception or in Python fatal error (which at least produces traceback). >>> import _gdbm as dbm >>> db = dbm.open('x.db', 'n') >>> open('x.db', 'wb').close() >>> db[b'a'] = b'b' Traceback (most recent call last): File "<stdin>", line 1, in <module> _gdbm.error: gdbm fatal: read error ---------- components: Extension Modules files: dbm_gdbm_fatal_error.patch keywords: patch messages: 223658 nosy: serhiy.storchaka priority: normal severity: normal stage: patch review status: open title: Fatal error in dbm.gdbm type: crash versions: Python 2.7, Python 3.4, Python 3.5 Added file: http://bugs.python.org/file36031/dbm_gdbm_fatal_error.patch _______________________________________ 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