From 8f53e1ee6ef0881cde5f78d92839407943957b58 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sat, 19 Jun 1993 20:35:26 +0000 Subject: [PATCH] (add_node): Move var last_node to file scope. --- lib-src/etags.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib-src/etags.c b/lib-src/etags.c index d0ba72be5e6..22b25678823 100644 --- a/lib-src/etags.c +++ b/lib-src/etags.c @@ -1103,13 +1103,16 @@ free_tree (node) * add_node is the only function allowed to add nodes, so it can * maintain state. */ +/* Must avoid static vars within functions since some systems + #define static as nothing. */ +static NODE *last_node = NULL; + void add_node (node, cur_node_p) NODE *node, **cur_node_p; { register int dif; register NODE *cur_node = *cur_node_p; - static NODE *last_node = NULL;/* careful */ if (cur_node == NULL) {