Mercurial > cpython-lru_cache-weakref
diff Modules/main.c @ 68102:e2f96bd29252
Issue #8914: fix various warnings from the Clang static analyzer v254.
| author | Brett Cannon <bcannon@gmail.com> |
|---|---|
| date | Tue, 22 Feb 2011 20:15:44 +0000 |
| parents | 608f3a6158a8 |
| children | b39270c6b8d1 |
line wrap: on
line diff
--- a/Modules/main.c Tue Feb 22 19:24:33 2011 +0000 +++ b/Modules/main.c Tue Feb 22 20:15:44 2011 +0000 @@ -577,7 +577,6 @@ if ((p = Py_GETENV("PYTHONEXECUTABLE")) && *p != '\0') { wchar_t* buffer; size_t len = strlen(p); - size_t r; buffer = malloc(len * sizeof(wchar_t)); if (buffer == NULL) { @@ -585,7 +584,7 @@ "not enough memory to copy PYTHONEXECUTABLE"); } - r = mbstowcs(buffer, p, len); + mbstowcs(buffer, p, len); Py_SetProgramName(buffer); /* buffer is now handed off - do not free */ } else {
