summaryrefslogtreecommitdiff
path: root/psutil/arch/osx
diff options
context:
space:
mode:
authorGiampaolo Rodola <g.rodola@gmail.com>2017-05-01 08:21:00 +0200
committerGiampaolo Rodola <g.rodola@gmail.com>2017-05-01 08:21:00 +0200
commit0cab2d1f98b4814e87b930193e5316897d70d047 (patch)
tree4c6e217787561cc9517b6ff63191aefba69de225 /psutil/arch/osx
parent043d5737d6eeab96aedd97f3a2fef35797304677 (diff)
downloadpsutil-0cab2d1f98b4814e87b930193e5316897d70d047.tar.gz
#1040: add replacement for PyUnicode_DecodeFSDefaultAndSize on Python 2; also get rid of the pstuil_ prefix and use the original Python names
Diffstat (limited to 'psutil/arch/osx')
-rw-r--r--psutil/arch/osx/process_info.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/psutil/arch/osx/process_info.c b/psutil/arch/osx/process_info.c
index ee395629..7d6861a5 100644
--- a/psutil/arch/osx/process_info.c
+++ b/psutil/arch/osx/process_info.c
@@ -177,7 +177,7 @@ psutil_get_cmdline(long pid) {
goto error;
while (arg_ptr < arg_end && nargs > 0) {
if (*arg_ptr++ == '\0') {
- py_arg = psutil_PyUnicode_DecodeFSDefault(curr_arg);
+ py_arg = PyUnicode_DecodeFSDefault(curr_arg);
if (! py_arg)
goto error;
if (PyList_Append(py_retlist, py_arg))
@@ -289,7 +289,7 @@ psutil_get_environ(long pid) {
arg_ptr = s + 1;
}
- py_ret = psutil_PyUnicode_DecodeFSDefaultAndSize(
+ py_ret = PyUnicode_DecodeFSDefaultAndSize(
procenv, arg_ptr - env_start + 1);
if (!py_ret) {
// XXX: don't want to free() this as per: