From: Oliver Kurth Date: Tue, 30 Apr 2019 20:24:25 +0000 (-0700) Subject: Changes to common header files not applicable to open-vm-tools. X-Git-Tag: stable-11.0.0~101 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5614d61a2b8353cd48095210afbcc89f66228ae7;p=thirdparty%2Fopen-vm-tools.git Changes to common header files not applicable to open-vm-tools. --- diff --git a/open-vm-tools/lib/include/hashTable.h b/open-vm-tools/lib/include/hashTable.h index 19083c01e..2ee4f3e18 100644 --- a/open-vm-tools/lib/include/hashTable.h +++ b/open-vm-tools/lib/include/hashTable.h @@ -1,5 +1,5 @@ /********************************************************* - * Copyright (C) 2004-2017 VMware, Inc. All rights reserved. + * Copyright (C) 2004-2017,2019 VMware, Inc. All rights reserved. * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published @@ -151,7 +151,7 @@ typedef struct PtrHashEntry { */ #define PTRHASH_CONTAINER(ptr, type, member) \ - ((type *)((char *)(ptr) - vmw_offsetof(type, member))) + ((type *)((char *)(ptr) - offsetof(type, member))) typedef int (*PtrHashForEachCallback)(PtrHashEntry *entry, const void *clientData); diff --git a/open-vm-tools/lib/include/vm_basic_defs.h b/open-vm-tools/lib/include/vm_basic_defs.h index 30b2b3250..a0cf3619d 100644 --- a/open-vm-tools/lib/include/vm_basic_defs.h +++ b/open-vm-tools/lib/include/vm_basic_defs.h @@ -129,14 +129,8 @@ * Simple macros */ - -/* Historical name. Deprecated. TODO: switch to offsetof */ -#ifndef vmw_offsetof -#define vmw_offsetof(TYPE, MEMBER) offsetof(TYPE, MEMBER) -#endif - #define VMW_CONTAINER_OF(ptr, type, member) \ - ((type *)((char *)(ptr) - vmw_offsetof(type, member))) + ((type *)((char *)(ptr) - offsetof(type, member))) #ifndef ARRAYSIZE #define ARRAYSIZE(a) (sizeof (a) / sizeof *(a))