# include <unistd.h>
# include "internal/cryptlib.h"
# include <openssl/rand.h>
-# include "internal/rand_int.h"
-# include "rand_lcl.h"
+# include "crypto/rand.h"
+# include "rand_local.h"
# include <descrip.h>
# include <dvidef.h>
# include <jpidef.h>
pid_t pid;
CRYPTO_THREAD_ID tid;
uint64_t time;
- } data = { 0 };
+ } data;
+
+ /* Erase the entire structure including any padding */
+ memset(&data, 0, sizeof(data));
/*
* Add process id, thread id, and a high resolution timestamp
struct {
CRYPTO_THREAD_ID tid;
uint64_t time;
- } data = { 0 };
+ } data;
+
+ /* Erase the entire structure including any padding */
+ memset(&data, 0, sizeof(data));
/*
* Add some noise from the thread id and a high resolution timer.
* concurrently (which is the case for the <master> drbg).
*/
data.tid = CRYPTO_THREAD_get_current_id();
+#if __CRTL_VER >= 80400000
sys$gettim_prec(&data.time);
+#else
+ sys$gettim((void*)&data.time);
+#endif
return rand_pool_add(pool, (unsigned char *)&data, sizeof(data), 0);
}