From: Amaury Forgeot d'Arc Date: Sun, 17 Oct 2010 08:34:22 +0000 (+0000) Subject: Fix compilation warning in _ctypes module on Window X-Git-Tag: v3.2a4~501 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=20f11fe43c47b68c8b9dd6539d2d40b66c9957f9;p=python Fix compilation warning in _ctypes module on Window --- diff --git a/Modules/_ctypes/libffi_msvc/ffi.c b/Modules/_ctypes/libffi_msvc/ffi.c index 65581a773f..5df4ba4be5 100644 --- a/Modules/_ctypes/libffi_msvc/ffi.c +++ b/Modules/_ctypes/libffi_msvc/ffi.c @@ -110,7 +110,7 @@ void ffi_prep_args(char *stack, extended_cif *ecif) argp += z; } - if (argp - stack > ecif->cif->bytes) + if (argp >= stack && (unsigned)(argp - stack) > ecif->cif->bytes) { Py_FatalError("FFI BUG: not enough stack space for arguments"); }