mirror of
https://github.com/jedisct1/libsodium.git
synced 2024-12-20 02:25:14 -07:00
Constify, add missing private include
This commit is contained in:
parent
0a6e10f75f
commit
52ff9c8980
@ -158,7 +158,7 @@ escrypt_r(escrypt_local_t *local, const uint8_t *passwd, size_t passwdlen,
|
||||
prefixlen = src - setting;
|
||||
|
||||
salt = src;
|
||||
src = (const uint8_t *) strrchr((char *) salt, '$');
|
||||
src = (const uint8_t *) strrchr((const char *) salt, '$');
|
||||
if (src) {
|
||||
saltlen = src - salt;
|
||||
} else {
|
||||
|
@ -1,5 +1,6 @@
|
||||
#include "crypto_stream_chacha20.h"
|
||||
#include "core.h"
|
||||
#include "private/chacha20_ietf_ext.h"
|
||||
#include "private/common.h"
|
||||
#include "private/implementations.h"
|
||||
#include "randombytes.h"
|
||||
|
@ -172,10 +172,10 @@ while (bytes >= 64) {
|
||||
diag1 = _mm_shuffle_epi32(diag1, 0x39); \
|
||||
diag2 = _mm_shuffle_epi32(diag2, 0x39); \
|
||||
diag3 = _mm_shuffle_epi32(diag3, 0x39); \
|
||||
in##A ^= *(uint32_t *) (m + (A * 4)); \
|
||||
in##B ^= *(uint32_t *) (m + (B * 4)); \
|
||||
in##C ^= *(uint32_t *) (m + (C * 4)); \
|
||||
in##D ^= *(uint32_t *) (m + (D * 4)); \
|
||||
in##A ^= *(const uint32_t *) (m + (A * 4)); \
|
||||
in##B ^= *(const uint32_t *) (m + (B * 4)); \
|
||||
in##C ^= *(const uint32_t *) (m + (C * 4)); \
|
||||
in##D ^= *(const uint32_t *) (m + (D * 4)); \
|
||||
*(uint32_t *) (c + (A * 4)) = in##A; \
|
||||
*(uint32_t *) (c + (B * 4)) = in##B; \
|
||||
*(uint32_t *) (c + (C * 4)) = in##C; \
|
||||
|
@ -432,7 +432,8 @@ if (bytes >= 512) {
|
||||
y##C2 = _mm256_permute2x128_si256(z##C, z##C2, 0x31); \
|
||||
y##D = _mm256_permute2x128_si256(z##D, z##D2, 0x20); \
|
||||
y##D2 = _mm256_permute2x128_si256(z##D, z##D2, 0x31); \
|
||||
y##A = _mm256_xor_si256(y##A, _mm256_loadu_si256((__m256i*) (m + 0))); \
|
||||
y##A = _mm256_xor_si256(y##A, \
|
||||
_mm256_loadu_si256((const __m256i*) (m + 0))); \
|
||||
y##B = _mm256_xor_si256( \
|
||||
y##B, _mm256_loadu_si256((const __m256i*) (m + 64))); \
|
||||
y##C = _mm256_xor_si256( \
|
||||
|
Loading…
Reference in New Issue
Block a user