aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-09-07 08:46:41 -0400
committerNick Mathewson <nickm@torproject.org>2018-09-07 08:46:41 -0400
commiteacaff6ccc8ea25859a1a9e14795bd4d4eac360f (patch)
treed041524f3699114ac8d9853860f9f75b977e32c1 /src
parenta5ed62f96cafa1be251f9a7b4aafa519de4c2645 (diff)
parentd2105ff5d530544538f6e98c1fba4d117223d12d (diff)
downloadtor-eacaff6ccc8ea25859a1a9e14795bd4d4eac360f.tar.gz
tor-eacaff6ccc8ea25859a1a9e14795bd4d4eac360f.zip
Merge remote-tracking branch 'teor/bug27461-032' into maint-0.3.2
Diffstat (limited to 'src')
-rw-r--r--src/or/main.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/or/main.c b/src/or/main.c
index 66b5920980..6c32ee5d87 100644
--- a/src/or/main.c
+++ b/src/or/main.c
@@ -3719,6 +3719,13 @@ tor_main(int argc, char *argv[])
#endif
/* On heap corruption, just give up; don't try to play along. */
HeapSetInformation(NULL, HeapEnableTerminationOnCorruption, NULL, 0);
+
+ /* SetProcessDEPPolicy is only supported on 32-bit Windows.
+ * (On 64-bit Windows it always fails, and some compilers don't like the
+ * PSETDEP cast.)
+ * 32-bit Windows defines _WIN32.
+ * 64-bit Windows defines _WIN32 and _WIN64. */
+#ifndef _WIN64
/* Call SetProcessDEPPolicy to permanently enable DEP.
The function will not resolve on earlier versions of Windows,
and failure is not dangerous. */
@@ -3732,6 +3739,7 @@ tor_main(int argc, char *argv[])
setdeppolicy(3);
}
}
+#endif /* !defined(_WIN64) */
#endif /* defined(_WIN32) */
configure_backtrace_handler(get_version());