Replace dead code with an assertion in winreg.c. (GH-10028)

This commit is contained in:
Zackery Spytz 2018-11-08 02:45:00 -07:00 committed by Serhiy Storchaka
parent a44d34e179
commit 5d95312fb8
1 changed files with 1 additions and 2 deletions

View File

@ -651,8 +651,7 @@ Py2Reg(PyObject *value, DWORD typ, BYTE **retDataBuf, DWORD *retDataSize)
t = PyList_GET_ITEM(value, j);
wstr = PyUnicode_AsUnicodeAndSize(t, &len);
if (wstr == NULL)
return FALSE;
assert(wstr);
wcscpy(P, wstr);
P += (len + 1);
}