From 73d605b0f759a2ff9f859f78f76098dcdb290d37 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Tue, 29 Jan 2013 17:38:15 -0500 Subject: Detect platforms where memset(0) doesn't set doubles to 0.0. This is allowed by the C statndard, which permits you to represent doubles any way you like, but in practice we have some code that assumes that memset() clears doubles in structs. Noticed as part of 7802 review; see 8081 for more info. --- src/win32/orconfig.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/win32/orconfig.h') diff --git a/src/win32/orconfig.h b/src/win32/orconfig.h index 6e45a2928..ef08fdb2b 100644 --- a/src/win32/orconfig.h +++ b/src/win32/orconfig.h @@ -151,6 +151,9 @@ /* Define to 1 iff NULL is represented by a 0 in memory. */ #define NULL_REP_IS_ZERO_BYTES 1 +/* Define to 1 iff memset(0) sets doubles to 0.0 */ +#define DOUBLE_0_REP_IS_ZERO_BYTES 1 + /* Name of package */ #define PACKAGE "tor" -- cgit v1.2.3