diff options
author | Giampaolo Rodola <g.rodola@gmail.com> | 2017-05-03 20:03:28 +0200 |
---|---|---|
committer | Giampaolo Rodola <g.rodola@gmail.com> | 2017-05-03 20:03:28 +0200 |
commit | 443763ff32d3bd23fee2a25e1812585cb5f20496 (patch) | |
tree | 1f91ff61c6589eb694e89b59aca8d5f5ece3e918 | |
parent | 734d603f58e65ed7353e95f2a0d9afaedb989e56 (diff) | |
download | psutil-443763ff32d3bd23fee2a25e1812585cb5f20496.tar.gz |
be explicit in using Py_UnicodeFromWideChar
-rw-r--r-- | psutil/_psutil_windows.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/psutil/_psutil_windows.c b/psutil/_psutil_windows.c index 83922a52..2366d030 100644 --- a/psutil/_psutil_windows.c +++ b/psutil/_psutil_windows.c @@ -669,7 +669,7 @@ psutil_proc_exe(PyObject *self, PyObject *args) { return PyErr_SetFromWindowsErr(0); } CloseHandle(hProcess); - return Py_BuildValue("u", exe); + return PyUnicode_FromWideChar(exe, wcslen(exe)); } |