[issue17978] Python crashes if Py_Initialize/Py_Finalize are called multiple times

2013-05-14 Thread Romulo A. Ceccon
New submission from Romulo A. Ceccon: I have patched (see attachment) Python 2.7.4 (as available for download at python.org/download) to disable initialization of Unicode (an embeded system requirement) and now it segfaults with the following program: #include Python.h int main

[issue17978] Python crashes if Py_Initialize/Py_Finalize are called multiple times

2013-05-14 Thread Romulo A. Ceccon
Romulo A. Ceccon added the comment: I've made some further investigation on this issue. Here's the output and the stack trace using --with-pydebug (and the attached patch applied): run no. 0 [8766 refs] free_list[0]-ob_refcnt before XDECREF: 2 run no. 1 [8844 refs

[issue1754] WindowsError messages are not properly encoded

2010-05-05 Thread Romulo A. Ceccon
Romulo A. Ceccon romulocec...@gmail.com added the comment: I think WindowsError's message should be English like other errors. FormatMessageW() function can take dwLanguageId parameter. So I think Python should pass `MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US)` to the parameter. On a non

[issue1754] WindowsError messages are not properly encoded

2008-01-07 Thread Romulo A. Ceccon
Romulo A. Ceccon added the comment: ... but the error message must be converted to str early (i.e when building the Exception). Wouldn't that create more problems? What if somebody wants to intercept the exception and do something with it, like, say, redirect it to a log file? The programmer

Re: Factory pattern implementation in Python

2006-12-04 Thread Romulo A. Ceccon
your description if the event number equals to the size of the associated data. I'm sorry, George. The event number has nothing to do with the size of the associated data. I meant the program has a way to discover the size from the event number. -- Romulo A. Ceccon 'romulo%s\x40yahoo.com.br