Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch make sure MSGBUFSIZE can't expand strangely by usin...
details: https://anonhg.NetBSD.org/src/rev/f350ac05448f
branches: trunk
changeset: 341249:f350ac05448f
user: mrg <mrg%NetBSD.org@localhost>
date: Tue Oct 27 22:28:56 2015 +0000
description:
make sure MSGBUFSIZE can't expand strangely by using parens.
diffstat:
sys/arch/amd64/include/param.h | 4 ++--
sys/arch/hppa/include/param.h | 4 ++--
sys/arch/i386/include/param.h | 4 ++--
sys/arch/sparc64/include/param.h | 4 ++--
4 files changed, 8 insertions(+), 8 deletions(-)
diffs (72 lines):
diff -r 36b70de882f8 -r f350ac05448f sys/arch/amd64/include/param.h
--- a/sys/arch/amd64/include/param.h Tue Oct 27 22:25:23 2015 +0000
+++ b/sys/arch/amd64/include/param.h Tue Oct 27 22:28:56 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: param.h,v 1.18 2012/04/20 22:23:24 rmind Exp $ */
+/* $NetBSD: param.h,v 1.19 2015/10/27 22:28:56 mrg Exp $ */
#ifdef __x86_64__
@@ -59,7 +59,7 @@
#define INTRSTACKSIZE 4096
#ifndef MSGBUFSIZE
-#define MSGBUFSIZE 8*NBPG /* default message buffer size */
+#define MSGBUFSIZE (8*NBPG) /* default message buffer size */
#endif
/*
diff -r 36b70de882f8 -r f350ac05448f sys/arch/hppa/include/param.h
--- a/sys/arch/hppa/include/param.h Tue Oct 27 22:25:23 2015 +0000
+++ b/sys/arch/hppa/include/param.h Tue Oct 27 22:28:56 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: param.h,v 1.20 2014/02/24 07:23:43 skrll Exp $ */
+/* $NetBSD: param.h,v 1.21 2015/10/27 22:28:56 mrg Exp $ */
/* $OpenBSD: param.h,v 1.12 2001/07/06 02:07:41 provos Exp $ */
@@ -66,7 +66,7 @@
#define USPACE (UPAGES * NBPG) /* pages for user struct and kstack */
#ifndef MSGBUFSIZE
-#define MSGBUFSIZE 2*NBPG /* default message buffer size */
+#define MSGBUFSIZE (2*NBPG) /* default message buffer size */
#endif
/*
diff -r 36b70de882f8 -r f350ac05448f sys/arch/i386/include/param.h
--- a/sys/arch/i386/include/param.h Tue Oct 27 22:25:23 2015 +0000
+++ b/sys/arch/i386/include/param.h Tue Oct 27 22:28:56 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: param.h,v 1.77 2012/04/20 22:23:24 rmind Exp $ */
+/* $NetBSD: param.h,v 1.78 2015/10/27 22:28:56 mrg Exp $ */
/*-
* Copyright (c) 1990 The Regents of the University of California.
@@ -101,7 +101,7 @@
#define INTRSTACKSIZE 8192
#ifndef MSGBUFSIZE
-#define MSGBUFSIZE 8*NBPG /* default message buffer size */
+#define MSGBUFSIZE (8*NBPG) /* default message buffer size */
#endif
/*
diff -r 36b70de882f8 -r f350ac05448f sys/arch/sparc64/include/param.h
--- a/sys/arch/sparc64/include/param.h Tue Oct 27 22:25:23 2015 +0000
+++ b/sys/arch/sparc64/include/param.h Tue Oct 27 22:28:56 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: param.h,v 1.55 2014/10/08 10:30:27 macallan Exp $ */
+/* $NetBSD: param.h,v 1.56 2015/10/27 22:28:56 mrg Exp $ */
/*
* Copyright (c) 1992, 1993
@@ -197,7 +197,7 @@
#define MCLBYTES (1 << MCLSHIFT) /* size of a m_buf cluster */
#if !defined (MSGBUFSIZE) /* options MSGBUFSIZE=integer */
-#define MSGBUFSIZE 4 * NBPG
+#define MSGBUFSIZE (4 * NBPG)
#else
#if INTSTACK - MSGBUF_VA - MSGBUFSIZE < 0
#error MSGBUFSIZE is too large
Home |
Main Index |
Thread Index |
Old Index