Skip to content

Commit

Permalink
Separate input/output flex_hash memory
Browse files Browse the repository at this point in the history
  • Loading branch information
MoneroOcean committed May 31, 2024
1 parent 3d8bf10 commit 2d1d781
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions src/crypto/flex/flex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ void SwapBytes(void *pv, unsigned int n)
}

void flex_hash(const char* input, char* output, cryptonight_ctx** ctx) {
uint32_t hash[64/4];
uint32_t hash[64/4], hash2[64/4];
sph_blake512_context ctx_blake;
sph_bmw512_context ctx_bmw;
sph_groestl512_context ctx_groestl;
Expand Down Expand Up @@ -289,7 +289,8 @@ void flex_hash(const char* input, char* output, cryptonight_ctx** ctx) {
sph_whirlpool_close(&ctx_whirlpool, hash);
break;
}
in = (void*) hash;
memcpy(hash2, hash, 64);
in = (void*) hash2;
size = 64;
}
sph_keccak256_init(&ctx_keccak);
Expand Down
2 changes: 1 addition & 1 deletion src/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#define APP_ID "xmrig"
#define APP_NAME "XMRig"
#define APP_DESC "XMRig miner"
#define APP_VERSION "6.21.3-mo12"
#define APP_VERSION "6.21.3-mo13"
#define APP_DOMAIN "xmrig.com"
#define APP_SITE "www.xmrig.com"
#define APP_COPYRIGHT "Copyright (C) 2016-2024 xmrig.com"
Expand Down

0 comments on commit 2d1d781

Please sign in to comment.