mirror of
https://github.com/openssl/openssl.git
synced 2025-01-18 13:44:20 +08:00
Solution proposal for issue #1647.
Avoid a memory alignment issue. Signed-off-by: Matthias Kraft <Matthias.Kraft@softwareag.com> CLA: trivial Reviewed-by: Andy Polyakov <appro@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/1650)
This commit is contained in:
parent
a22f9c84b4
commit
af5883fec9
@ -451,6 +451,7 @@ int main(int argc, char *argv[])
|
||||
BIO *rbio;
|
||||
BIO *wbio;
|
||||
BIO *err;
|
||||
time_t now = 0;
|
||||
int testresult = 0;
|
||||
int ret;
|
||||
int i;
|
||||
@ -464,7 +465,9 @@ int main(int argc, char *argv[])
|
||||
RAND_bytes(master_secret, sizeof(master_secret));
|
||||
RAND_bytes(cookie, sizeof(cookie));
|
||||
RAND_bytes(server_random + 4, sizeof(server_random) - 4);
|
||||
time((void *)server_random);
|
||||
|
||||
now = time(NULL);
|
||||
memcpy(server_random, &now, sizeof(now));
|
||||
|
||||
sess = client_session();
|
||||
if (sess == NULL) {
|
||||
|
Loading…
Reference in New Issue
Block a user