]> granicus.if.org Git - python/commitdiff
Fix compilation warning on Windows
authorAmaury Forgeot d'Arc <amauryfa@gmail.com>
Mon, 16 Aug 2010 22:11:29 +0000 (22:11 +0000)
committerAmaury Forgeot d'Arc <amauryfa@gmail.com>
Mon, 16 Aug 2010 22:11:29 +0000 (22:11 +0000)
PC/winreg.c

index c134a352e0351962f5faa2b0e78bd34224a662ba..eacb4c2723ebe20c936ce8ea3c82778f08edd9e1 100644 (file)
@@ -1129,7 +1129,7 @@ PyEnumValue(PyObject *self, PyObject *args)
     int index;
     long rc;
     wchar_t *retValueBuf;
-    wchar_t *tmpBuf;
+    BYTE *tmpBuf;
     BYTE *retDataBuf;
     DWORD retValueSize, bufValueSize;
     DWORD retDataSize, bufDataSize;
@@ -1177,7 +1177,7 @@ PyEnumValue(PyObject *self, PyObject *args)
             break;
 
         bufDataSize *= 2;
-        tmpBuf = (wchar_t *)PyMem_Realloc(retDataBuf, bufDataSize);
+        tmpBuf = (BYTE *)PyMem_Realloc(retDataBuf, bufDataSize);
         if (tmpBuf == NULL) {
             PyErr_NoMemory();
             retVal = NULL;