summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorZackery Spytz <zspytz@gmail.com>2019-05-06 16:56:51 (GMT)
committerBrett Cannon <54418+brettcannon@users.noreply.github.com>2019-05-06 16:56:50 (GMT)
commit1a2252ed39bc1b71cdaa935d7726d82909af93ab (patch)
tree7a816ef20b914628f61cce377a9b245933ff6ec9 /Python
parentae2c32f32b61f3b141ba4b0b1ad71781d2f9a1a1 (diff)
downloadcpython-1a2252ed39bc1b71cdaa935d7726d82909af93ab.zip
cpython-1a2252ed39bc1b71cdaa935d7726d82909af93ab.tar.gz
cpython-1a2252ed39bc1b71cdaa935d7726d82909af93ab.tar.bz2
bpo-36594: Fix incorrect use of %p in format strings (GH-12769)
In addition, fix some other minor violations of C99.
Diffstat (limited to 'Python')
-rw-r--r--Python/sysmodule.c8
-rw-r--r--Python/thread_pthread.h4
2 files changed, 6 insertions, 6 deletions
diff --git a/Python/sysmodule.c b/Python/sysmodule.c
index fbdeb9b..1290164 100644
--- a/Python/sysmodule.c
+++ b/Python/sysmodule.c
@@ -1750,7 +1750,7 @@ _alloc_preinit_entry(const wchar_t *value)
PyMem_SetAllocator(PYMEM_DOMAIN_RAW, &old_alloc);
return node;
-};
+}
static int
_append_preinit_entry(_Py_PreInitEntry *optionlist, const wchar_t *value)
@@ -1772,7 +1772,7 @@ _append_preinit_entry(_Py_PreInitEntry *optionlist, const wchar_t *value)
last_entry->next = new_entry;
}
return 0;
-};
+}
static void
_clear_preinit_entries(_Py_PreInitEntry *optionlist)
@@ -1789,7 +1789,7 @@ _clear_preinit_entries(_Py_PreInitEntry *optionlist)
current = next;
}
PyMem_SetAllocator(PYMEM_DOMAIN_RAW, &old_alloc);
-};
+}
static void
_clear_all_preinit_options(void)
@@ -1820,7 +1820,7 @@ _PySys_ReadPreInitOptions(void)
_clear_all_preinit_options();
return 0;
-};
+}
static PyObject *
get_warnoptions(void)
diff --git a/Python/thread_pthread.h b/Python/thread_pthread.h
index 1f4f36d..4c106d9 100644
--- a/Python/thread_pthread.h
+++ b/Python/thread_pthread.h
@@ -339,7 +339,7 @@ PyThread_allocate_lock(void)
}
}
- dprintf(("PyThread_allocate_lock() -> %p\n", lock));
+ dprintf(("PyThread_allocate_lock() -> %p\n", (void *)lock));
return (PyThread_type_lock)lock;
}
@@ -521,7 +521,7 @@ PyThread_allocate_lock(void)
}
}
- dprintf(("PyThread_allocate_lock() -> %p\n", lock));
+ dprintf(("PyThread_allocate_lock() -> %p\n", (void *)lock));
return (PyThread_type_lock) lock;
}