From 80b8b39899a09c7516920cda5fd343b3086d4824 Mon Sep 17 00:00:00 2001 From: Denis Vlasenko Date: Mon, 25 Jun 2007 10:55:35 +0000 Subject: Consolidate ARRAY_SIZE macro; remove one unneeded global var (walter harms ) --- shell/lash.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'shell/lash.c') diff --git a/shell/lash.c b/shell/lash.c index 4e8b23776..e5c7ef670 100644 --- a/shell/lash.c +++ b/shell/lash.c @@ -146,8 +146,8 @@ static const struct built_in_command bltins[] = { /* to do: add ulimit */ }; -#define VEC_SIZE(v) (sizeof(v)/sizeof(v[0])) -#define VEC_LAST(v) v[VEC_SIZE(v)-1] + +#define VEC_LAST(v) v[ARRAY_SIZE(v)-1] static int shell_context; /* Type prompt trigger (PS1 or PS2) */ -- cgit v1.2.3