From: Jeremy Allison Date: Tue, 29 Mar 2022 01:23:05 +0000 (-0700) Subject: s4: torture: Add CHECK_VAL macro to smb2/rename.c. Not yet used. X-Git-Tag: tevent-0.12.0~199 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e862a2d9ec4e7bec1dd58490e9dee47d543b9154;p=thirdparty%2Fsamba.git s4: torture: Add CHECK_VAL macro to smb2/rename.c. Not yet used. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15038 Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source4/torture/smb2/rename.c b/source4/torture/smb2/rename.c index 5055cf24344..60234769797 100644 --- a/source4/torture/smb2/rename.c +++ b/source4/torture/smb2/rename.c @@ -30,6 +30,20 @@ #include "librpc/gen_ndr/security.h" +#define CHECK_VAL(v, correct) \ + do { \ + if ((v) != (correct)) { \ + torture_result(torture, \ + TORTURE_FAIL, \ + "(%s): wrong value for %s got " \ + "0x%llx - should be 0x%llx\n", \ + __location__, #v, \ + (unsigned long long)v, \ + (unsigned long long)correct); \ + ret = false; \ + goto done; \ + }} while (0) + #define CHECK_STATUS(status, correct) do { \ if (!NT_STATUS_EQUAL(status, correct)) { \ torture_result(torture, TORTURE_FAIL, \