concat hash no realloc
This commit is contained in:
parent
b7b786c69a
commit
aa5ac80337
@ -58,6 +58,5 @@ void concat_data(pub_data *data, unsigned char *buf) {
|
|||||||
|
|
||||||
// Concat hash2 to hash1 (hash1 is modified)
|
// Concat hash2 to hash1 (hash1 is modified)
|
||||||
void concat_hash(unsigned char *hash1, unsigned char *hash2, size_t size) {
|
void concat_hash(unsigned char *hash1, unsigned char *hash2, size_t size) {
|
||||||
hash1 = (unsigned char*) realloc(hash1, size + 16);
|
|
||||||
memcpy(hash1+size, hash2, 16);
|
memcpy(hash1+size, hash2, 16);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user