summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
Diffstat (limited to 'utils')
-rw-r--r--utils/awk/run.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/utils/awk/run.c b/utils/awk/run.c
index a6cbb406..7c2740d2 100644
--- a/utils/awk/run.c
+++ b/utils/awk/run.c
@@ -1209,7 +1209,10 @@ Cell *split(Node **a, int nnn) /* split(a[0], a[1], a[2]); a[3] is type */
FATAL("illegal type of split");
sep = *fs;
ap = execute(a[1]); /* array name */
+ n = y->tval;
+ y->tval |= DONTFREE; /* split(a[x], a); */
freesymtab(ap);
+ y->tval = n;
dprintf( ("split: s=|%s|, a=%s, sep=|%s|\n", s, ap->nval, fs) );
ap->tval &= ~STR;
ap->tval |= ARR;