mirror of
https://github.com/python/cpython.git
synced 2025-07-09 20:35:26 +00:00
If MS_WIN64 is defined, MS_WINDOWS is also defined: #ifdef can be simplified.
This commit is contained in:
parent
b28a375f2f
commit
14b9b11098
7 changed files with 20 additions and 20 deletions
|
@ -16,13 +16,13 @@ extern wchar_t* _Py_DecodeUTF8_surrogateescape(const char *s, Py_ssize_t size);
|
|||
PyObject *
|
||||
_Py_device_encoding(int fd)
|
||||
{
|
||||
#if defined(MS_WINDOWS) || defined(MS_WIN64)
|
||||
#if defined(MS_WINDOWS)
|
||||
UINT cp;
|
||||
#endif
|
||||
if (!_PyVerify_fd(fd) || !isatty(fd)) {
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
#if defined(MS_WINDOWS) || defined(MS_WIN64)
|
||||
#if defined(MS_WINDOWS)
|
||||
if (fd == 0)
|
||||
cp = GetConsoleCP();
|
||||
else if (fd == 1 || fd == 2)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue