summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2017-10-03 11:21:52 +0000
committerderaadt <deraadt@openbsd.org>2017-10-03 11:21:52 +0000
commit109396cc19348dfbe97d65eb80ea885d585f1dce (patch)
treecbb3df847d8e83e501c0ce36f553fb9b1052fc2b
parentFix PermitOpen crash; spotted by benno@, ok dtucker@ deraadt@ (diff)
downloadwireguard-openbsd-109396cc19348dfbe97d65eb80ea885d585f1dce.tar.xz
wireguard-openbsd-109396cc19348dfbe97d65eb80ea885d585f1dce.zip
work around config(8) modifying bss, using __attribute__ ((section(".data"))).
From yasuoka. I really want this fixed in a different way after release is finished.
-rw-r--r--sys/conf/param.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/conf/param.c b/sys/conf/param.c
index 1912eca8ea2..abaefb33f3a 100644
--- a/sys/conf/param.c
+++ b/sys/conf/param.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: param.c,v 1.37 2016/05/06 19:45:35 kettenis Exp $ */
+/* $OpenBSD: param.c,v 1.38 2017/10/03 11:21:52 deraadt Exp $ */
/* $NetBSD: param.c,v 1.16 1996/03/12 03:08:40 mrg Exp $ */
/*
@@ -81,7 +81,7 @@
int hz = HZ;
int tick = 1000000 / HZ;
int tickadj = 240000 / (60 * HZ); /* can adjust 240ms in 60s */
-struct timezone tz = { TIMEZONE, DST };
+struct timezone tz __attribute__ ((section(".data"))) = { TIMEZONE, DST };
#define NPROCESS (30 + 16 * MAXUSERS)
#define NTEXT (80 + NPROCESS / 8) /* actually the object cache */
#define NVNODE (NPROCESS * 2 + NTEXT + 100)