From: Katy Feng Date: Thu, 16 Nov 2023 17:21:20 +0000 (-0800) Subject: Change to common header file not applicable to open-vm-tools. X-Git-Tag: stable-12.4.0~46 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=14ada379295c86b9eed8d407753c88610312a6e8;p=thirdparty%2Fopen-vm-tools.git Change to common header file not applicable to open-vm-tools. --- diff --git a/open-vm-tools/lib/include/vm_basic_defs.h b/open-vm-tools/lib/include/vm_basic_defs.h index 0f8c2c0a2..8f5d226fd 100644 --- a/open-vm-tools/lib/include/vm_basic_defs.h +++ b/open-vm-tools/lib/include/vm_basic_defs.h @@ -605,9 +605,21 @@ typedef int pid_t; #undef X86_ONLY #ifdef VM_X86_ANY -#define X86_ONLY(...) __VA_ARGS__ -#else -#define X86_ONLY(...) +# ifdef _MSC_VER +/* + * Old MSVC versions (such as MSVC 14.29.30133, used to build Workstation's + * offset checker) are notorious to have non-standard __VA_ARGS__ handling. + */ +# define X86_ONLY(x) x +# else +# define X86_ONLY(...) __VA_ARGS__ +# endif +#else +# ifdef _MSC_VER +# define X86_ONLY(x) +# else +# define X86_ONLY(...) +# endif #endif #undef DEBUG_ONLY