summaryrefslogtreecommitdiff
path: root/Modules/_ctypes
diff options
context:
space:
mode:
authorZackery Spytz <zspytz@gmail.com>2019-03-31 10:00:12 -0600
committerSerhiy Storchaka <storchaka@gmail.com>2019-03-31 19:00:12 +0300
commit48600c72c1afe1096c2412a135a43f8cdd895195 (patch)
treea50bd32741659abf19629639624ad0ede68b7590 /Modules/_ctypes
parent79da388a4016e24c4258dcc62cd0fa9dde0acb5b (diff)
downloadcpython-git-48600c72c1afe1096c2412a135a43f8cdd895195.tar.gz
bpo-35947: Fix a compiler warning in _ctypes.c's StructUnionType_paramfunc(). (GH-12629)
Diffstat (limited to 'Modules/_ctypes')
-rw-r--r--Modules/_ctypes/_ctypes.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_ctypes/_ctypes.c b/Modules/_ctypes/_ctypes.c
index 7479edaf11..03f8e75609 100644
--- a/Modules/_ctypes/_ctypes.c
+++ b/Modules/_ctypes/_ctypes.c
@@ -406,7 +406,7 @@ StructUnionType_paramfunc(CDataObject *self)
CDataObject *copied_self;
StgDictObject *stgdict;
- if (self->b_size > sizeof(void*)) {
+ if ((size_t)self->b_size > sizeof(void*)) {
void *new_ptr = PyMem_Malloc(self->b_size);
if (new_ptr == NULL)
return NULL;