summaryrefslogtreecommitdiff
path: root/shells/posh/patches/patch-aa
blob: 831e964a58c30173da6cf76ef098b726267c05a5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
$NetBSD: patch-aa,v 1.1 2004/09/08 12:00:09 jmmv Exp $

--- src/builtins.c.orig	2004-09-08 13:54:59.000000000 +0200
+++ src/builtins.c
@@ -450,6 +450,8 @@ int posh_builtin_exitreturn(int argc, ch
 
 static void ers_walk(const void *nodep, const VISIT which, const int UNUSED(depth)) {
 	struct tbl *vp;
+	struct tbl *tvp;
+	int any_set = 0;
 
 	switch(which) {
 		case preorder:
@@ -460,8 +458,6 @@ static void ers_walk(const void *nodep, 
 		case postorder:
 		case leaf:
 			vp = *(struct tbl **)nodep;
-			struct tbl *tvp;
-			int any_set = 0;
 			/*
 			 * See if the parameter is set (for arrays, if any
 			 * element is set).