From: Oliver Kurth Date: Fri, 15 Sep 2017 18:23:05 +0000 (-0700) Subject: More C++ goodness X-Git-Tag: stable-10.2.0~524 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c23472eab7d7ec8b24f52d8ecb69c027e0ee4a1b;p=thirdparty%2Fopen-vm-tools.git More C++ goodness C++ after the includes --- diff --git a/open-vm-tools/lib/include/asyncsocket.h b/open-vm-tools/lib/include/asyncsocket.h index 27bf03d28..0ae1c3a8b 100644 --- a/open-vm-tools/lib/include/asyncsocket.h +++ b/open-vm-tools/lib/include/asyncsocket.h @@ -49,14 +49,14 @@ #define INCLUDE_ALLOW_USERLEVEL #include "includeCheck.h" -#if defined(__cplusplus) -extern "C" { -#endif - #ifdef __APPLE__ #include #endif +#if defined(__cplusplus) +extern "C" { +#endif + /* * Error codes */ diff --git a/open-vm-tools/lib/include/auth.h b/open-vm-tools/lib/include/auth.h index afc86d476..386773e06 100644 --- a/open-vm-tools/lib/include/auth.h +++ b/open-vm-tools/lib/include/auth.h @@ -19,10 +19,6 @@ #ifndef _AUTH_H_ #define _AUTH_H_ -#if defined(__cplusplus) -extern "C" { -#endif - /* * auth.h -- * @@ -46,6 +42,10 @@ extern "C" { typedef const struct passwd * AuthToken; #endif +#if defined(__cplusplus) +extern "C" { +#endif + #if _WIN32 BOOL Auth_StoreAccountInformation(const char *username, const char *password); diff --git a/open-vm-tools/lib/include/backdoor.h b/open-vm-tools/lib/include/backdoor.h index 22fe36866..373d981e4 100644 --- a/open-vm-tools/lib/include/backdoor.h +++ b/open-vm-tools/lib/include/backdoor.h @@ -40,15 +40,15 @@ #ifndef _BACKDOOR_H_ #define _BACKDOOR_H_ -#if defined(__cplusplus) -extern "C" { -#endif - #include "vm_basic_types.h" #include "vm_assert.h" #include "backdoor_types.h" +#if defined(__cplusplus) +extern "C" { +#endif + void Backdoor(Backdoor_proto *bp); // IN/OUT diff --git a/open-vm-tools/lib/include/circList.h b/open-vm-tools/lib/include/circList.h index 0618a38a8..61b062f49 100644 --- a/open-vm-tools/lib/include/circList.h +++ b/open-vm-tools/lib/include/circList.h @@ -33,12 +33,12 @@ #define INCLUDE_ALLOW_VMKERNEL #include "includeCheck.h" +#include "vmware.h" + #if defined(__cplusplus) extern "C" { #endif -#include "vmware.h" - typedef struct ListItem { struct ListItem *prev; struct ListItem *next; diff --git a/open-vm-tools/lib/include/codeset.h b/open-vm-tools/lib/include/codeset.h index 1bdac0d03..66f421099 100644 --- a/open-vm-tools/lib/include/codeset.h +++ b/open-vm-tools/lib/include/codeset.h @@ -49,14 +49,14 @@ #ifndef __CODESET_H__ # define __CODESET_H__ -#if defined(__cplusplus) -extern "C" { -#endif - #include "vm_basic_types.h" #include "vm_assert.h" #include "dynbuf.h" +#if defined(__cplusplus) +extern "C" { +#endif + /* * These platforms use UTF-8 (or pretend to): * FreeBSD: really UTF-8 diff --git a/open-vm-tools/lib/include/config.h b/open-vm-tools/lib/include/config.h index 95aa59871..47e3a7089 100644 --- a/open-vm-tools/lib/include/config.h +++ b/open-vm-tools/lib/include/config.h @@ -23,13 +23,13 @@ #define INCLUDE_ALLOW_VMCORE #include "includeCheck.h" +#include "vm_basic_types.h" +#include "preference.h" + #if defined(__cplusplus) extern "C" { #endif -#include "vm_basic_types.h" -#include "preference.h" - /* * Well-known configuration variable names */ diff --git a/open-vm-tools/lib/include/cryptoError.h b/open-vm-tools/lib/include/cryptoError.h index 8a189230f..fdc2176c5 100644 --- a/open-vm-tools/lib/include/cryptoError.h +++ b/open-vm-tools/lib/include/cryptoError.h @@ -29,14 +29,14 @@ #define INCLUDE_ALLOW_VMCORE #include "includeCheck.h" -#if defined(__cplusplus) -extern "C" { -#endif - #include "vmware.h" typedef int CryptoError; +#if defined(__cplusplus) +extern "C" { +#endif + /* * This set of errors should not be expanded beyond a maximum value of 15 * without also updating the code for AIOMgr errors, which allots only 4 bits