From 1e2399b91cfd9895939876c4fb47af11c13ddf89 Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Fri, 6 Mar 2015 15:12:52 -0600 Subject: The "no }" error with find | xargs sed is because toy_init() wasn't blanking the GLOBALS() block on a recursive call. (How that ever worked...) --- main.c | 1 + 1 file changed, 1 insertion(+) (limited to 'main.c') diff --git a/main.c b/main.c index a81cfb92..4644d198 100644 --- a/main.c +++ b/main.c @@ -116,6 +116,7 @@ void toy_init(struct toy_list *which, char *argv[]) if (toys.optargs != toys.argv+1) free(toys.optargs); memset(&toys, 0, offsetof(struct toy_context, rebound)); + if (toys.recursion > 1) memset(&this, 0, sizeof(this)); // Subset of init needed by singlemain. toy_singleinit(which, argv); -- cgit v1.2.3