Module Name:    src
Committed By:   wiz
Date:           Wed Nov 25 21:08:59 UTC 2020

Modified Files:
        src/sys/kern: kern_exec.c

Log Message:
Define LMSG outside the MAXTSIZ check so it also exists in non-MAXTSIZ kernels.


To generate a diff of this commit:
cvs rdiff -u -r1.502 -r1.503 src/sys/kern/kern_exec.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/kern/kern_exec.c
diff -u src/sys/kern/kern_exec.c:1.502 src/sys/kern/kern_exec.c:1.503
--- src/sys/kern/kern_exec.c:1.502	Tue Oct  6 13:38:00 2020
+++ src/sys/kern/kern_exec.c	Wed Nov 25 21:08:59 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: kern_exec.c,v 1.502 2020/10/06 13:38:00 christos Exp $	*/
+/*	$NetBSD: kern_exec.c,v 1.503 2020/11/25 21:08:59 wiz Exp $	*/
 
 /*-
  * Copyright (c) 2008, 2019, 2020 The NetBSD Foundation, Inc.
@@ -62,7 +62,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_exec.c,v 1.502 2020/10/06 13:38:00 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_exec.c,v 1.503 2020/11/25 21:08:59 wiz Exp $");
 
 #include "opt_exec.h"
 #include "opt_execfmt.h"
@@ -498,10 +498,12 @@ check_exec(struct lwp *l, struct exec_pa
 			}
 
 			/* check limits */
+#ifdef DIAGNOSTIC
+#define LMSG "%s: rejecting due to %s limit (%ju > %ju)\n"
+#endif
 #ifdef MAXTSIZ
 			if (epp->ep_tsize > MAXTSIZ) {
 #ifdef DIAGNOSTIC
-#define LMSG "%s: rejecting due to %s limit (%ju > %ju)\n"
 				printf(LMSG, __func__, "text",
 				    (uintmax_t)epp->ep_tsize,
 				    (uintmax_t)MAXTSIZ);

Reply via email to