1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-01-08 22:08:02 +00:00

MSVS fix.

This commit is contained in:
troky 2014-12-03 23:07:14 +01:00
parent 4ba8a68043
commit 4ced43ba2b
3 changed files with 7 additions and 6 deletions

View File

@ -1177,7 +1177,8 @@ void neoscrypt(const uchar *password, uchar *output, uint profile) {
r = (1 << ((profile >> 5) & 0x7)); r = (1 << ((profile >> 5) & 0x7));
} }
uchar stack[(N + 3) * r * 2 * SCRYPT_BLOCK_SIZE + stack_align]; uchar *stack;
stack = (uchar *)malloc((N + 3) * r * 2 * SCRYPT_BLOCK_SIZE + stack_align);
/* X = r * 2 * SCRYPT_BLOCK_SIZE */ /* X = r * 2 * SCRYPT_BLOCK_SIZE */
X = (uint *) &stack[stack_align & ~(stack_align - 1)]; X = (uint *) &stack[stack_align & ~(stack_align - 1)];
/* Z is a copy of X for ChaCha */ /* Z is a copy of X for ChaCha */
@ -1284,7 +1285,7 @@ void neoscrypt(const uchar *password, uchar *output, uint profile) {
#endif #endif
} }
free(stack);
} }
void neoscrypt_regenhash(struct work *work) void neoscrypt_regenhash(struct work *work)

View File

@ -1491,7 +1491,7 @@ extern void kill_work(void);
//helper macro to preserve existing code //helper macro to preserve existing code
#ifndef switch_pools #ifndef switch_pools
#define switch_pools(p) __switch_pools(p, TRUE) #define switch_pools(p) __switch_pools(p, true)
#endif #endif
extern void __switch_pools(struct pool *selected, bool saveprio); extern void __switch_pools(struct pool *selected, bool saveprio);

View File

@ -67,11 +67,11 @@
#endif #endif
#define VERSION "v5.0.1" #define VERSION "v5.1.0"
#define PACKAGE_NAME "sgminer" #define PACKAGE_NAME "sgminer"
#define PACKAGE_TARNAME "sgminer" #define PACKAGE_TARNAME "sgminer"
#define PACKAGE_VERSION "5.0.1" #define PACKAGE_VERSION "5.1.0"
#define PACKAGE_STRING "sgminer 5.0.1" #define PACKAGE_STRING "sgminer 5.1.0"
#define PACKAGE "sgminer" #define PACKAGE "sgminer"
#define SGMINER_PREFIX "" #define SGMINER_PREFIX ""