From 735042e9ac9041ea3ce20e612a9231551562bf3b Mon Sep 17 00:00:00 2001 From: deraadt Date: Mon, 19 Jan 2015 02:44:53 +0000 Subject: [PATCH] gcc does not understand that the loop conditionally sets bsod before using it, so it warns... Copy the warning silencing code from the same function in ../ld.so --- libexec/ld.so/ldconfig/library.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libexec/ld.so/ldconfig/library.c b/libexec/ld.so/ldconfig/library.c index 4b1ff1059e7..e42c0c7def1 100644 --- a/libexec/ld.so/ldconfig/library.c +++ b/libexec/ld.so/ldconfig/library.c @@ -1,4 +1,4 @@ -/* $OpenBSD: library.c,v 1.7 2015/01/16 16:18:07 deraadt Exp $ */ +/* $OpenBSD: library.c,v 1.8 2015/01/19 02:44:53 deraadt Exp $ */ /* * Copyright (c) 2006 Dale Rahn * @@ -199,6 +199,7 @@ nohints: else searchpath = _dl_default_path; } + memset(&bsod, 0, sizeof(bsod)); for (pp = searchpath; *pp != NULL; pp++) { if ((dd = opendir(*pp)) != NULL) { match = 0; -- 2.20.1