Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc/regex protect MIN from re-definition



details:   https://anonhg.NetBSD.org/src/rev/264cc2510c0e
branches:  trunk
changeset: 959796:264cc2510c0e
user:      christos <christos%NetBSD.org@localhost>
date:      Thu Feb 25 13:42:16 2021 +0000

description:
protect MIN from re-definition

diffstat:

 lib/libc/regex/regcomp.c |  6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diffs (28 lines):

diff -r 855df19bd03b -r 264cc2510c0e lib/libc/regex/regcomp.c
--- a/lib/libc/regex/regcomp.c  Thu Feb 25 13:41:58 2021 +0000
+++ b/lib/libc/regex/regcomp.c  Thu Feb 25 13:42:16 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: regcomp.c,v 1.40 2021/02/24 18:13:21 christos Exp $    */
+/*     $NetBSD: regcomp.c,v 1.41 2021/02/25 13:42:16 christos Exp $    */
 
 /*-
  * SPDX-License-Identifier: BSD-3-Clause
@@ -47,7 +47,7 @@
 static char sccsid[] = "@(#)regcomp.c  8.5 (Berkeley) 3/20/94";
 __FBSDID("$FreeBSD: head/lib/libc/regex/regcomp.c 368359 2020-12-05 03:18:48Z kevans $");
 #endif
-__RCSID("$NetBSD: regcomp.c,v 1.40 2021/02/24 18:13:21 christos Exp $");
+__RCSID("$NetBSD: regcomp.c,v 1.41 2021/02/25 13:42:16 christos Exp $");
 
 #define _OPENBSD_SOURCE
 #define REGEX_GNU_EXTENSIONS
@@ -218,7 +218,9 @@
 #define        DROP(n) (p->slen -= (n))
 
 /* Macro used by computejump()/computematchjump() */
+#ifndef MIN
 #define MIN(a,b)       ((a)<(b)?(a):(b))
+#endif
 
 static int                             /* 0 success, otherwise REG_something */
 regcomp_internal(regex_t * __restrict preg,



Home | Main Index | Thread Index | Old Index