From f85b118d2150847cc333895296bc230e367be6b5 Mon Sep 17 00:00:00 2001 From: "dtucker@openbsd.org" Date: Fri, 29 May 2020 09:02:44 +0000 Subject: [PATCH] upstream: Pass a NULL instead of zeroed out va_list from dollar_expand. The original intent was in case there's some platform where va_list is not a pointer equivalent, but on i386 this chokes on the memset. This unbreaks that build, but will require further consideration. OpenBSD-Commit-ID: 7b90afcd8e1137a1d863204060052aef415baaf7 --- misc.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/misc.c b/misc.c index 3ec02d79e..9ba913c3e 100644 --- a/misc.c +++ b/misc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: misc.c,v 1.150 2020/05/29 04:25:40 dtucker Exp $ */ +/* $OpenBSD: misc.c,v 1.151 2020/05/29 09:02:44 dtucker Exp $ */ /* * Copyright (c) 2000 Markus Friedl. All rights reserved. * Copyright (c) 2005-2020 Damien Miller. All rights reserved. @@ -1212,10 +1212,8 @@ dollar_expand(int *parseerr, const char *string) { char *ret; int err; - va_list ap; - memset(ap, 0, sizeof(ap)); /* unused */ - ret = vdollar_percent_expand(&err, 1, 0, string, ap); + ret = vdollar_percent_expand(&err, 1, 0, string, NULL); if (parseerr != NULL) *parseerr = err; return ret;