|
|
@ -2003,7 +2003,7 @@ bool regeneratehash(const struct work *work) |
|
|
|
uint32_t *data32 = (uint32_t *)(work->data); |
|
|
|
uint32_t *data32 = (uint32_t *)(work->data); |
|
|
|
unsigned char swap[128]; |
|
|
|
unsigned char swap[128]; |
|
|
|
uint32_t *swap32 = (uint32_t *)swap; |
|
|
|
uint32_t *swap32 = (uint32_t *)swap; |
|
|
|
unsigned char hash1[64]; |
|
|
|
unsigned char hash1[32]; |
|
|
|
uint32_t *hash32 = (uint32_t *)(work->hash); |
|
|
|
uint32_t *hash32 = (uint32_t *)(work->hash); |
|
|
|
uint32_t difficulty = 0; |
|
|
|
uint32_t difficulty = 0; |
|
|
|
uint32_t diffbytes = 0; |
|
|
|
uint32_t diffbytes = 0; |
|
|
@ -2016,7 +2016,7 @@ bool regeneratehash(const struct work *work) |
|
|
|
swap32[i] = swab32(data32[i]); |
|
|
|
swap32[i] = swab32(data32[i]); |
|
|
|
|
|
|
|
|
|
|
|
sha2(swap, 80, hash1, false); |
|
|
|
sha2(swap, 80, hash1, false); |
|
|
|
sha2(hash1, 64, (unsigned char *)(work->hash), false); |
|
|
|
sha2(hash1, 32, (unsigned char *)(work->hash), false); |
|
|
|
|
|
|
|
|
|
|
|
difficulty = swab32(*((uint32_t *)(work->data + 72))); |
|
|
|
difficulty = swab32(*((uint32_t *)(work->data + 72))); |
|
|
|
|
|
|
|
|
|
|
|