summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2016-11-18 10:51:57 +0100
committerJeremy Allison <jra@samba.org>2016-11-20 17:29:08 +0100
commit9c0f2576d8aa3dd95be1c5ddda2b10d891add0bc (patch)
treed08be253b488f7ace01e241f29eea729b74e1a10
parent95b738badbf0f2344db13eb1e0d80891240998e4 (diff)
downloadsamba-9c0f2576d8aa3dd95be1c5ddda2b10d891add0bc.tar.gz
lib:torture: Make variables const
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12415 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
-rw-r--r--lib/torture/torture.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/torture/torture.h b/lib/torture/torture.h
index 5b957fa46fd..45332b2ef7c 100644
--- a/lib/torture/torture.h
+++ b/lib/torture/torture.h
@@ -547,7 +547,7 @@ static inline void torture_dump_data_str_cb(const char *buf, void *private_data)
} while(0)
#define torture_assert_guid_equal(torture_ctx,got,expected,cmt)\
- do { struct GUID __got = (got), __expected = (expected); \
+ do {const struct GUID __got = (got), __expected = (expected); \
if (!GUID_equal(&__got, &__expected)) { \
torture_result(torture_ctx, TORTURE_FAIL, \
__location__": "#got" was %s, expected %s: %s", \
@@ -565,7 +565,7 @@ static inline void torture_dump_data_str_cb(const char *buf, void *private_data)
} while(0)
#define torture_assert_sid_equal(torture_ctx,got,expected,cmt)\
- do { struct dom_sid *__got = (got), *__expected = (expected); \
+ do {const struct dom_sid *__got = (got), *__expected = (expected); \
if (!dom_sid_equal(__got, __expected)) { \
torture_result(torture_ctx, TORTURE_FAIL, \
__location__": "#got" was %s, expected %s: %s", \
@@ -575,7 +575,7 @@ static inline void torture_dump_data_str_cb(const char *buf, void *private_data)
} while(0)
#define torture_assert_not_null(torture_ctx,got,cmt)\
- do { void *__got = (got); \
+ do {const void *__got = (got); \
if (__got == NULL) { \
torture_result(torture_ctx, TORTURE_FAIL, \
__location__": "#got" was NULL, expected != NULL: %s", \
@@ -585,7 +585,7 @@ static inline void torture_dump_data_str_cb(const char *buf, void *private_data)
} while(0)
#define torture_assert_not_null_goto(torture_ctx,got,ret,label,cmt)\
- do { void *__got = (got); \
+ do {const void *__got = (got); \
if (__got == NULL) { \
torture_result(torture_ctx, TORTURE_FAIL, \
__location__": "#got" was NULL, expected != NULL: %s", \