From bbefe8051a56b3cf834bf71c8f55fdfd88802b9d Mon Sep 17 00:00:00 2001 From: Oliver Kurth Date: Mon, 15 Apr 2019 11:33:00 -0700 Subject: [PATCH] Common header file change not applicable to open-vm-tools. --- open-vm-tools/lib/include/circList.h | 30 +++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/open-vm-tools/lib/include/circList.h b/open-vm-tools/lib/include/circList.h index 4cecfe090..fab2b0c22 100644 --- a/open-vm-tools/lib/include/circList.h +++ b/open-vm-tools/lib/include/circList.h @@ -1,5 +1,5 @@ /********************************************************* - * Copyright (C) 1998-2017 VMware, Inc. All rights reserved. + * Copyright (C) 1998-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 @@ -345,6 +345,34 @@ CircList_Push(ListItem *p, // IN } +/* + *---------------------------------------------------------------------- + * + * CircList_InsertAfter -- + * + * Adds a new member to the list after the provided item. Assumes p + * is not a member of a list already. + * + * Result: + * None. + * + * Side effects: + * None. + * + *---------------------------------------------------------------------- + */ + +static INLINE void +CircList_InsertAfter(ListItem *p, // IN: + ListItem *after) // IN: +{ + p->prev = after; + p->next = after->next; + p->next->prev = p; + after->next = p; +} + + /* *---------------------------------------------------------------------- * -- 2.47.3