summaryrefslogtreecommitdiff
path: root/include/test.h
diff options
context:
space:
mode:
authorPeter Jones <pjones@redhat.com>2021-07-02 13:57:40 -0400
committerPeter Jones <pjones@redhat.com>2021-07-20 09:44:25 -0400
commit5f08e671e4eb4ec43c1bf667e67f02b7454e13b0 (patch)
tree8afe5fac9a9d2159ac29d3e5afe82cab59c555de /include/test.h
parent32697356c6a99a53bf0027ceb3e348278799b9ef (diff)
downloadefi-boot-shim-5f08e671e4eb4ec43c1bf667e67f02b7454e13b0.tar.gz
efi-boot-shim-5f08e671e4eb4ec43c1bf667e67f02b7454e13b0.zip
test.h: add some decls for some of the stuff in efilib.h
In some test cases, it's useful to be able to call some of the very common stuff in gnu-efi's efilib.h (i.e. CompareGuid()), but including that header itself is too big for me to tackle right now. This patch adds a few more decls to test.h. Signed-off-by: Peter Jones <pjones@redhat.com>
Diffstat (limited to 'include/test.h')
-rw-r--r--include/test.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/test.h b/include/test.h
index 1d9c7be3..811f92bf 100644
--- a/include/test.h
+++ b/include/test.h
@@ -48,6 +48,17 @@
#define FreePool(x) free(x)
#define ReallocatePool(old, oldsz, newsz) realloc(old, newsz)
+INTN StrnCmp(IN CONST CHAR16 *s1,
+ IN CONST CHAR16 *s2,
+ IN UINTN len);
+CHAR16 *StrDuplicate(IN CONST CHAR16 *Src);
+UINTN StrLen(IN CONST CHAR16 *s1);
+UINTN StrSize(IN CONST CHAR16 *s1);
+VOID StrCat(IN CHAR16 *Dest, IN CONST CHAR16 *Src);
+CHAR16 *DevicePathToStr(EFI_DEVICE_PATH *DevPath);
+
+#define CompareGuid(a, b) memcmp(a, b, sizeof(a))
+
extern int debug;
#ifdef dprint
#undef dprint