]> git.proxmox.com Git - mirror_edk2.git/commit
MdePkg/BaseLib: Add IsNodeInList() function.
authorMarvin.Haeuser@outlook.com <Marvin.Haeuser@outlook.com>
Thu, 3 Aug 2017 19:52:08 +0000 (03:52 +0800)
committerLiming Gao <liming.gao@intel.com>
Wed, 16 Aug 2017 08:55:30 +0000 (16:55 +0800)
commitd0aef615acb0b1cb3c1662a7d2562ea7bef471ec
treeddc1f574dd4157472349c39c93cd59af605c7992
parent8a765da2a3da23607cd46c18c7d05937cd09d799
MdePkg/BaseLib: Add IsNodeInList() function.

This patch adds IsNodeInList() to BaseLib, which verifies the given
Node is part of the doubly-linked List provided.

V2:
  - Rename "List" to "FirstEntry" and "Node" to "SecondEntry" to clarify that
    "FirstEntry" does not need to be the doubly-linked list's head node.

V3:
  - Remove ASSERTs from IsNodeInList() which are present in
    InternalBaseLibIsListValid().

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Marvin Haeuser <Marvin.Haeuser@outlook.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
MdePkg/Include/Library/BaseLib.h
MdePkg/Library/BaseLib/BaseLibInternals.h
MdePkg/Library/BaseLib/LinkedList.c