Tim Peters <tim.one@comcast.net> writes: > As I said, it's worthy of a comment. *I* have no idea whether > HAVE_LANGINFO_H and/or CODESET are defined on Windows. If the correctness > of this code *relies* on that they're not defined on Windows (as it still > appears it does), an "#if Windows ... #error" would even be appropriate. Correctness of this code is established throught the sequence if (Py_FileSystemDefaultEncoding == NULL) fileencoding_uses_locale = 1; if (fileencoding_uses_locale) { The only way the free can be ever executed is if fileencoding_uses_locale. This can be only set if Py_FileSystemDefaultEncoding was NULL at some earlier point. Correctness of this code does not rely on whether certain defines are defined on Windows. Regards, Martin
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4