mirror of
https://github.com/curl/curl.git
synced 2026-05-15 16:46:19 +03:00
curlcheck.h: add verify_memory
This check verifies that a pointer contains the correct data.
This commit is contained in:
parent
1602ed6ba1
commit
7af54ef9a5
1 changed files with 7 additions and 0 deletions
|
|
@ -23,6 +23,13 @@
|
|||
unitfail++; \
|
||||
}
|
||||
|
||||
#define verify_memory(dynamic, check, len) \
|
||||
if(memcmp(dynamic, check, len)) { \
|
||||
fprintf(stderr, "%s:%d The dynamic string didn't match '%s'\n", \
|
||||
__FILE__, __LINE__, check); \
|
||||
unitfail++; \
|
||||
}
|
||||
|
||||
extern int unitfail;
|
||||
|
||||
#define UNITTEST_START \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue