From: Serhiy Storchaka Date: Mon, 11 Nov 2013 05:47:35 +0000 (+0200) Subject: Fixed compile error on Windows caused by arithmetic with void * pointers X-Git-Tag: v3.4.0b1~319 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=23a7827c451b151fe1e403d30e8460850b2d69ea;p=thirdparty%2FPython%2Fcpython.git Fixed compile error on Windows caused by arithmetic with void * pointers (issue #16685). --- diff --git a/Modules/audioop.c b/Modules/audioop.c index df4a524b3162..5c83a7d6b0ab 100644 --- a/Modules/audioop.c +++ b/Modules/audioop.c @@ -287,9 +287,9 @@ static int stepsizeTable[89] = { 15289, 16818, 18500, 20350, 22385, 24623, 27086, 29794, 32767 }; -#define GETINTX(T, cp, i) (*(T *)((cp) + (i))) -#define SETINTX(T, cp, i, val) do { \ - *(T *)((cp) + (i)) = (T)(val); \ +#define GETINTX(T, cp, i) (*(T *)((unsigned char *)(cp) + (i))) +#define SETINTX(T, cp, i, val) do { \ + *(T *)((unsigned char *)(cp) + (i)) = (T)(val); \ } while (0)