mirror of
https://github.com/curl/curl.git
synced 2026-04-14 22:31:41 +03:00
clang-tidy: enable readability-math-missing-parentheses, adjust code
No functional changes. Also: - md4, md5: drop redundant parentheses from macro values. Closes #20691
This commit is contained in:
parent
29bca12978
commit
65262be0ab
40 changed files with 85 additions and 80 deletions
12
lib/md4.c
12
lib/md4.c
|
|
@ -218,12 +218,12 @@ typedef struct md4_ctx MD4_CTX;
|
|||
#define MD4_SET(n) (*(const uint32_t *)(const void *)&ptr[(n) * 4])
|
||||
#define MD4_GET(n) MD4_SET(n)
|
||||
#else
|
||||
#define MD4_SET(n) (ctx->block[(n)] = \
|
||||
(uint32_t)ptr[(n) * 4] | \
|
||||
((uint32_t)ptr[(n) * 4 + 1] << 8) | \
|
||||
((uint32_t)ptr[(n) * 4 + 2] << 16) | \
|
||||
((uint32_t)ptr[(n) * 4 + 3] << 24))
|
||||
#define MD4_GET(n) (ctx->block[(n)])
|
||||
#define MD4_SET(n) (ctx->block[n] = \
|
||||
(uint32_t)ptr[(n) * 4] | \
|
||||
((uint32_t)ptr[((n) * 4) + 1] << 8) | \
|
||||
((uint32_t)ptr[((n) * 4) + 2] << 16) | \
|
||||
((uint32_t)ptr[((n) * 4) + 3] << 24))
|
||||
#define MD4_GET(n) ctx->block[n]
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue