Patch #569753: Remove support for WIN16.
Rename all occurrences of MS_WIN32 to MS_WINDOWS.
diff --git a/Modules/_codecsmodule.c b/Modules/_codecsmodule.c
index 0c49f7f..aed3c42 100644
--- a/Modules/_codecsmodule.c
+++ b/Modules/_codecsmodule.c
@@ -316,7 +316,7 @@
 		       size);
 }
 
-#if defined(MS_WIN32) && defined(HAVE_USABLE_WCHAR_T)
+#if defined(MS_WINDOWS) && defined(HAVE_USABLE_WCHAR_T)
 
 static PyObject *
 mbcs_decode(PyObject *self,
@@ -334,7 +334,7 @@
 		       size);
 }
 
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 /* --- Encoder ------------------------------------------------------------ */
 
@@ -636,7 +636,7 @@
     return v;
 }
 
-#if defined(MS_WIN32) && defined(HAVE_USABLE_WCHAR_T)
+#if defined(MS_WINDOWS) && defined(HAVE_USABLE_WCHAR_T)
 
 static PyObject *
 mbcs_encode(PyObject *self,
@@ -661,7 +661,7 @@
     return v;
 }
 
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 #endif /* Py_USING_UNICODE */
 
 /* --- Module API --------------------------------------------------------- */
@@ -695,7 +695,7 @@
     {"charmap_decode", 		charmap_decode,			METH_VARARGS},
     {"readbuffer_encode",	readbuffer_encode,		METH_VARARGS},
     {"charbuffer_encode",	charbuffer_encode,		METH_VARARGS},
-#if defined(MS_WIN32) && defined(HAVE_USABLE_WCHAR_T)
+#if defined(MS_WINDOWS) && defined(HAVE_USABLE_WCHAR_T)
     {"mbcs_encode", 		mbcs_encode,			METH_VARARGS},
     {"mbcs_decode", 		mbcs_decode,			METH_VARARGS},
 #endif
diff --git a/Modules/_hotshot.c b/Modules/_hotshot.c
index 06a6824..3426e97 100644
--- a/Modules/_hotshot.c
+++ b/Modules/_hotshot.c
@@ -12,7 +12,7 @@
  * Which timer to use should be made more configurable, but that should not
  * be difficult.  This will do for now.
  */
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 #include <windows.h>
 #include <direct.h>    /* for getcwd() */
 typedef __int64 hs_time;
@@ -90,7 +90,7 @@
 static PyObject * ProfilerError = NULL;
 
 
-#ifndef MS_WIN32
+#ifndef MS_WINDOWS
 #ifdef GETTIMEOFDAY_NO_TZ
 #define GETTIMEOFDAY(ptv) gettimeofday((ptv))
 #else
@@ -818,7 +818,7 @@
 get_tdelta(ProfilerObject *self)
 {
     int tdelta;
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
     hs_time tv;
     hs_time diff;
 
@@ -909,7 +909,7 @@
 
 /* A couple of useful helper functions. */
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 static LARGE_INTEGER frequency = {0, 0};
 #endif
 
@@ -921,7 +921,7 @@
 {
     hs_time tv1, tv2;
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
     hs_time diff;
     QueryPerformanceFrequency(&frequency);
 #endif
@@ -929,7 +929,7 @@
     GETTIMEOFDAY(&tv1);
     while (1) {
         GETTIMEOFDAY(&tv2);
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
         diff = tv2 - tv1;
         if (diff != 0) {
             timeofday_diff = (unsigned long)diff;
@@ -945,7 +945,7 @@
         }
 #endif
     }
-#if defined(MS_WIN32) || defined(macintosh) || defined(PYOS_OS2)
+#if defined(MS_WINDOWS) || defined(macintosh) || defined(PYOS_OS2)
     rusage_diff = -1;
 #else
     {
@@ -1448,7 +1448,7 @@
     else
         pack_add_info(self, "executable-version", buffer);
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
     PyOS_snprintf(cwdbuffer, sizeof(cwdbuffer), "%I64d", frequency.QuadPart);
     pack_add_info(self, "reported-performance-frequency", cwdbuffer);
 #else
@@ -1553,7 +1553,7 @@
 }
 
 PyDoc_VAR(resolution__doc__) = 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 PyDoc_STR(
 "resolution() -> (performance-counter-ticks, update-frequency)\n"
 "Return the resolution of the timer provided by the QueryPerformanceCounter()\n"
@@ -1580,7 +1580,7 @@
             calibrate();
             calibrate();
         }
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
         result = Py_BuildValue("ii", timeofday_diff, frequency.LowPart);
 #else
         result = Py_BuildValue("ii", timeofday_diff, rusage_diff);
diff --git a/Modules/_localemodule.c b/Modules/_localemodule.c
index e6bacb4..80c2767 100644
--- a/Modules/_localemodule.c
+++ b/Modules/_localemodule.c
@@ -25,7 +25,7 @@
 #include <libintl.h>
 #endif
 
-#if defined(MS_WIN32)
+#if defined(MS_WINDOWS)
 #define WINDOWS_LEAN_AND_MEAN
 #include <windows.h>
 #endif
@@ -363,7 +363,7 @@
     return result;
 }
 
-#if defined(MS_WIN32)
+#if defined(MS_WINDOWS)
 static PyObject*
 PyLocale_getdefaultlocale(PyObject* self)
 {
@@ -627,7 +627,7 @@
    METH_VARARGS, strcoll__doc__},
   {"strxfrm", (PyCFunction) PyLocale_strxfrm, 
    METH_VARARGS, strxfrm__doc__},
-#if defined(MS_WIN32) || defined(macintosh)
+#if defined(MS_WINDOWS) || defined(macintosh)
   {"_getdefaultlocale", (PyCFunction) PyLocale_getdefaultlocale, METH_NOARGS},
 #endif
 #ifdef HAVE_LANGINFO_H
diff --git a/Modules/mmapmodule.c b/Modules/mmapmodule.c
index 3164a27..eca67d3 100644
--- a/Modules/mmapmodule.c
+++ b/Modules/mmapmodule.c
@@ -20,11 +20,11 @@
 
 #include <Python.h>
 
-#ifndef MS_WIN32
+#ifndef MS_WINDOWS
 #define UNIX
 #endif
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 #include <windows.h>
 static int
 my_getpagesize(void)
@@ -75,7 +75,7 @@
 	size_t	size;
 	size_t	pos;
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	HANDLE	map_handle;
 	HANDLE	file_handle;
 	char *	tagname;
@@ -92,7 +92,7 @@
 static void
 mmap_object_dealloc(mmap_object *m_obj)
 {
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	if (m_obj->data != NULL)
 		UnmapViewOfFile (m_obj->data);
 	if (m_obj->map_handle != INVALID_HANDLE_VALUE)
@@ -101,7 +101,7 @@
 		CloseHandle (m_obj->file_handle);
 	if (m_obj->tagname)
 		PyMem_Free(m_obj->tagname);
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 #ifdef UNIX
 	if (m_obj->data!=NULL) {
@@ -118,7 +118,7 @@
 {
         if (!PyArg_ParseTuple(args, ":close"))
 		return NULL;
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	/* For each resource we maintain, we need to check
 	   the value is valid, and if so, free the resource 
 	   and set the member value to an invalid value so
@@ -138,7 +138,7 @@
 		CloseHandle (self->file_handle);
 		self->file_handle = INVALID_HANDLE_VALUE;
 	}
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 #ifdef UNIX
 	munmap(self->data, self->size);
@@ -149,7 +149,7 @@
 	return (Py_None);
 }
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 #define CHECK_VALID(err)						\
 do {									\
     if (!self->map_handle) {						\
@@ -157,7 +157,7 @@
 	return err;							\
     }									\
 } while (0)
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 #ifdef UNIX
 #define CHECK_VALID(err)						\
@@ -336,7 +336,7 @@
         if (!PyArg_ParseTuple(args, ":size"))
 		return NULL;
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	if (self->file_handle != INVALID_HANDLE_VALUE) {
 		return (Py_BuildValue (
 			"l", (long)
@@ -344,7 +344,7 @@
 	} else {
 		return (Py_BuildValue ("l", (long) self->size) );
 	}
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 #ifdef UNIX
 	{
@@ -376,7 +376,7 @@
 	if (!PyArg_ParseTuple (args, "l:resize", &new_size) || 
 	    !is_resizeable(self)) {
 		return NULL;
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	} else { 
 		DWORD dwErrCode = 0;
 		/* First, unmap the file view */
@@ -414,7 +414,7 @@
 		}
 		PyErr_SetFromWindowsErr(dwErrCode);
 		return (NULL);
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 #ifdef UNIX
 #ifndef HAVE_MREMAP 
@@ -467,10 +467,10 @@
 				 "flush values out of range");
 		return NULL;
 	} else {
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 		return (Py_BuildValue("l", (long)
                                       FlushViewOfFile(self->data+offset, size)));
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 #ifdef UNIX
 		/* XXX semantics of return value? */
 		/* XXX flags for msync? */
@@ -909,7 +909,7 @@
 }
 #endif /* UNIX */
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 static PyObject *
 new_mmap_object(PyObject *self, PyObject *args, PyObject *kwdict)
 {
@@ -1042,7 +1042,7 @@
 	PyErr_SetFromWindowsErr(dwErr);
 	return (NULL);
 }
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 /* List of functions exported by this module */
 static struct PyMethodDef mmap_functions[] = {
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index 2a77ee3..163263f 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -4,7 +4,7 @@
 /* This file is also used for Windows NT/MS-Win and OS/2.  In that case the
    module actually calls itself 'nt' or 'os2', not 'posix', and a few
    functions are either unimplemented or implemented differently.  The source
-   assumes that for Windows NT, the macro 'MS_WIN32' is defined independent
+   assumes that for Windows NT, the macro 'MS_WINDOWS' is defined independent
    of the compiler used.  Different compilers define their own feature
    test macro, e.g. '__BORLANDC__' or '_MSC_VER'.  For OS/2, the compiler
    independent macro PYOS_OS2 should be defined.  On OS/2 the default
@@ -82,15 +82,12 @@
 #else
 #ifdef _MSC_VER		/* Microsoft compiler */
 #define HAVE_GETCWD     1
-#ifdef MS_WIN32
 #define HAVE_SPAWNV	1
 #define HAVE_EXECV      1
 #define HAVE_PIPE       1
 #define HAVE_POPEN      1
 #define HAVE_SYSTEM	1
 #define HAVE_CWAIT	1
-#else /* 16-bit Windows */
-#endif /* !MS_WIN32 */
 #else
 #if defined(PYOS_OS2) && defined(PYCC_GCC)
 /* Everything needed is defined in PC/os2emx/pyconfig.h */
@@ -222,13 +219,8 @@
 #include "osdefs.h"
 #define WINDOWS_LEAN_AND_MEAN
 #include <windows.h>
-#ifdef MS_WIN32
 #define popen	_popen
 #define pclose	_pclose
-#else /* 16-bit Windows */
-#include <dos.h>
-#include <ctype.h>
-#endif /* MS_WIN32 */
 #endif /* _MSC_VER */
 
 #if defined(PYCC_VACPP) && defined(PYOS_OS2)
@@ -268,7 +260,7 @@
 
 /* choose the appropriate stat and fstat functions and return structs */
 #undef STAT
-#if defined(MS_WIN64) || defined(MS_WIN32)
+#if defined(MS_WIN64) || defined(MS_WINDOWS)
 #	define STAT _stati64
 #	define FSTAT _fstati64
 #	define STRUCT_STAT struct _stati64
@@ -367,7 +359,7 @@
 	return rc;
 }
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 static PyObject *
 win32_error(char* function, char* filename)
 {
@@ -684,17 +676,17 @@
 	char *pathfree = NULL;  /* this memory must be free'd */
 	int res;
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	int pathlen;
 	char pathcopy[MAX_PATH];
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 	if (!PyArg_ParseTuple(args, format,
 	                      Py_FileSystemDefaultEncoding, &path))
 		return NULL;
 	pathfree = path;
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	pathlen = strlen(path);
 	/* the library call can blow up if the file name is too long! */
 	if (pathlen > MAX_PATH) {
@@ -719,7 +711,7 @@
 			path = pathcopy;
 		}
 	}
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 	Py_BEGIN_ALLOW_THREADS
 	res = (*statfunc)(path, &st);
@@ -991,7 +983,7 @@
 {
 	/* XXX Should redo this putting the (now four) versions of opendir
 	   in separate files instead of having them all here... */
-#if defined(MS_WIN32) && !defined(HAVE_OPENDIR)
+#if defined(MS_WINDOWS) && !defined(HAVE_OPENDIR)
 
 	PyObject *d, *v;
 	HANDLE hFindFile;
@@ -1047,67 +1039,6 @@
 
 	return d;
 
-#elif defined(_MSC_VER) /* 16-bit Windows */
-
-#ifndef MAX_PATH
-#define MAX_PATH	250
-#endif
-	char *name, *pt;
-	int len;
-	PyObject *d, *v;
-	char namebuf[MAX_PATH+5];
-	struct _find_t ep;
-
-	if (!PyArg_ParseTuple(args, "t#:listdir", &name, &len))
-		return NULL;
-	if (len >= MAX_PATH) {
-		PyErr_SetString(PyExc_ValueError, "path too long");
-		return NULL;
-	}
-	strcpy(namebuf, name);
-	for (pt = namebuf; *pt; pt++)
-		if (*pt == ALTSEP)
-			*pt = SEP;
-	if (namebuf[len-1] != SEP)
-		namebuf[len++] = SEP;
-	strcpy(namebuf + len, "*.*");
-
-	if ((d = PyList_New(0)) == NULL)
-		return NULL;
-
-	if (_dos_findfirst(namebuf, _A_RDONLY |
-			   _A_HIDDEN | _A_SYSTEM | _A_SUBDIR, &ep) != 0)
-        {
-		errno = ENOENT;
-		return posix_error_with_filename(name);
-	}
-	do {
-		if (ep.name[0] == '.' &&
-		    (ep.name[1] == '\0' ||
-		     ep.name[1] == '.' &&
-		     ep.name[2] == '\0'))
-			continue;
-		strcpy(namebuf, ep.name);
-		for (pt = namebuf; *pt; pt++)
-			if (isupper(*pt))
-				*pt = tolower(*pt);
-		v = PyString_FromString(namebuf);
-		if (v == NULL) {
-			Py_DECREF(d);
-			d = NULL;
-			break;
-		}
-		if (PyList_Append(d, v) != 0) {
-			Py_DECREF(v);
-			Py_DECREF(d);
-			d = NULL;
-			break;
-		}
-		Py_DECREF(v);
-	} while (_dos_findnext(&ep) == 0);
-
-	return d;
-
 #elif defined(PYOS_OS2)
 
 #ifndef MAX_PATH
@@ -1220,7 +1151,7 @@
 #endif /* which OS */
 }  /* end of posix_listdir */
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 /* A helper function for abspath on win32 */
 static PyObject *
 posix__getfullpathname(PyObject *self, PyObject *args)
@@ -1240,7 +1171,7 @@
 		return win32_error("GetFullPathName", inbuf);
 	return PyString_FromString(outbuf);
 } /* end of posix__getfullpathname */
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 PyDoc_STRVAR(posix_mkdir__doc__,
 "mkdir(path [, mode=0777])\n\n\
@@ -3050,7 +2981,7 @@
 
 #endif /* PYCC_??? */
 
-#elif defined(MS_WIN32)
+#elif defined(MS_WINDOWS)
 
 /*
  * Portable 'popen' replacement for Win32.
@@ -4211,7 +4142,7 @@
 #endif /* HAVE_TIMES */
 
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 #define HAVE_TIMES	/* so the method table will pick it up */
 static PyObject *
 posix_times(PyObject *self, PyObject *args)
@@ -4237,7 +4168,7 @@
 		(double)0,
 		(double)0);
 }
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 
 #ifdef HAVE_TIMES
 PyDoc_STRVAR(posix_times__doc__,
@@ -4414,7 +4345,7 @@
 posix_lseek(PyObject *self, PyObject *args)
 {
 	int fd, how;
-#if defined(MS_WIN64) || defined(MS_WIN32)
+#if defined(MS_WIN64) || defined(MS_WINDOWS)
 	LONG_LONG pos, res;
 #else
 	off_t pos, res;
@@ -4441,7 +4372,7 @@
 		return NULL;
 
 	Py_BEGIN_ALLOW_THREADS
-#if defined(MS_WIN64) || defined(MS_WIN32)
+#if defined(MS_WIN64) || defined(MS_WINDOWS)
 	res = _lseeki64(fd, pos, how);
 #else
 	res = lseek(fd, pos, how);
@@ -4590,7 +4521,7 @@
 
     return Py_BuildValue("(ii)", read, write);
 #else
-#if !defined(MS_WIN32)
+#if !defined(MS_WINDOWS)
 	int fds[2];
 	int res;
 	if (!PyArg_ParseTuple(args, ":pipe"))
@@ -4601,7 +4532,7 @@
 	if (res != 0)
 		return posix_error();
 	return Py_BuildValue("(ii)", fds[0], fds[1]);
-#else /* MS_WIN32 */
+#else /* MS_WINDOWS */
 	HANDLE read, write;
 	int read_fd, write_fd;
 	BOOL ok;
@@ -4615,7 +4546,7 @@
 	read_fd = _open_osfhandle((Py_intptr_t)read, 0);
 	write_fd = _open_osfhandle((Py_intptr_t)write, 1);
 	return Py_BuildValue("(ii)", read_fd, write_fd);
-#endif /* MS_WIN32 */
+#endif /* MS_WINDOWS */
 #endif
 }
 #endif  /* HAVE_PIPE */
@@ -5189,7 +5120,7 @@
 		  "tempnam is a potential security risk to your program") < 0)
 	    return NULL;
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
     name = _tempnam(dir, pfx);
 #else
     name = tempnam(dir, pfx);
@@ -6250,7 +6181,7 @@
     return NULL;
 }
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 PyDoc_STRVAR(win32_startfile__doc__,
 "startfile(filepath) - Start a file with its associated application.\n\
 \n\
@@ -6390,7 +6321,7 @@
 #endif /* HAVE_PLOCK */
 #ifdef HAVE_POPEN
 	{"popen",	posix_popen, METH_VARARGS, posix_popen__doc__},
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	{"popen2",	win32_popen2, METH_VARARGS},
 	{"popen3",	win32_popen3, METH_VARARGS},
 	{"popen4",	win32_popen4, METH_VARARGS},
@@ -6542,7 +6473,7 @@
 	{"pathconf",	posix_pathconf, METH_VARARGS, posix_pathconf__doc__},
 #endif
 	{"abort",	posix_abort, METH_VARARGS, posix_abort__doc__},
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 	{"_getfullpathname",	posix__getfullpathname, METH_VARARGS, NULL},
 #endif
 	{NULL,		NULL}		 /* Sentinel */
diff --git a/Modules/signalmodule.c b/Modules/signalmodule.c
index 240e9a9..25d5d94 100644
--- a/Modules/signalmodule.c
+++ b/Modules/signalmodule.c
@@ -6,7 +6,7 @@
 #include "Python.h"
 #include "intrcheck.h"
 
-#ifdef MS_WIN32
+#ifdef MS_WINDOWS
 #include <process.h>
 #endif
 
diff --git a/Modules/timemodule.c b/Modules/timemodule.c
index b2b58bf..8f2c4f8 100644
--- a/Modules/timemodule.c
+++ b/Modules/timemodule.c
@@ -29,23 +29,20 @@
 #else
 #ifdef MS_WINDOWS
 #include <windows.h>
-#if defined(MS_WIN16) || defined(__BORLANDC__)
+#if defined(__BORLANDC__)
 /* These overrides not needed for Win32 */
 #define timezone _timezone
 #define tzname _tzname
 #define daylight _daylight
-#endif /* MS_WIN16 || __BORLANDC__ */
-#ifdef MS_WIN16
-#define altzone _altzone
-#endif /* MS_WIN16 */
+#endif /* __BORLANDC__ */
 #endif /* MS_WINDOWS */
 #endif /* !__WATCOMC__ || __QNX__ */
 
-#if defined(MS_WIN32) && !defined(MS_WIN64) && !defined(__BORLANDC__)
+#if defined(MS_WINDOWS) && !defined(MS_WIN64) && !defined(__BORLANDC__)
 /* Win32 has better clock replacement
    XXX Win64 does not yet, but might when the platform matures. */
 #undef HAVE_CLOCK /* We have our own version down below */
-#endif /* MS_WIN32 && !MS_WIN64 */
+#endif /* MS_WINDOWS && !MS_WIN64 */
 
 #if defined(PYOS_OS2)
 #define INCL_DOS
@@ -141,7 +138,7 @@
 }
 #endif /* HAVE_CLOCK */
 
-#if defined(MS_WIN32) && !defined(MS_WIN64) && !defined(__BORLANDC__)
+#if defined(MS_WINDOWS) && !defined(MS_WIN64) && !defined(__BORLANDC__)
 /* Due to Mark Hammond and Tim Peters */
 static PyObject *
 time_clock(PyObject *self, PyObject *args)
@@ -170,7 +167,7 @@
 }
 
 #define HAVE_CLOCK /* So it gets included in the methods */
-#endif /* MS_WIN32 && !MS_WIN64 */
+#endif /* MS_WINDOWS && !MS_WIN64 */
 
 #ifdef HAVE_CLOCK
 PyDoc_STRVAR(clock_doc,
@@ -736,7 +733,7 @@
 static int
 floatsleep(double secs)
 {
-/* XXX Should test for MS_WIN32 first! */
+/* XXX Should test for MS_WINDOWS first! */
 #if defined(HAVE_SELECT) && !defined(__BEOS__) && !defined(__EMX__)
 	struct timeval t;
 	double frac;
@@ -771,36 +768,7 @@
 	Py_BEGIN_ALLOW_THREADS
 	delay((int)(secs * 1000 + 0.5));  /* delay() uses milliseconds */
 	Py_END_ALLOW_THREADS
-#elif defined(MSDOS)
-	struct timeb t1, t2;
-	double frac;
-	extern double fmod(double, double);
-	extern double floor(double);
-	if (secs <= 0.0)
-		return;
-	frac = fmod(secs, 1.0);
-	secs = floor(secs);
-	ftime(&t1);
-	t2.time = t1.time + (int)secs;
-	t2.millitm = t1.millitm + (int)(frac*1000.0);
-	while (t2.millitm >= 1000) {
-		t2.time++;
-		t2.millitm -= 1000;
-	}
-	for (;;) {
-#ifdef QUICKWIN
-		Py_BEGIN_ALLOW_THREADS
-		_wyield();
-		Py_END_ALLOW_THREADS
-#endif
-		if (PyErr_CheckSignals())
-			return -1;
-		ftime(&t1);
-		if (t1.time > t2.time ||
-		    t1.time == t2.time && t1.millitm >= t2.millitm)
-			break;
-	}
-#elif defined(MS_WIN32)
+#elif defined(MS_WINDOWS)
 	{
 		double millisecs = secs * 1000.0;
 		if (millisecs > (double)ULONG_MAX) {