summaryrefslogtreecommitdiffstats
path: root/source/ap/ksh93/patches/ksh-20120801-emptyarrayinit.patch
blob: c888b319d9dfe85447b22461e6a4558594bffe0a (about) (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
--- ksh-20120801/src/cmd/ksh93/sh/array.c	2014-12-11 16:39:34.253860675 -0200
+++ ksh-20120801/src/cmd/ksh93/sh/array.c	2014-12-11 16:39:40.794857083 -0200
@@ -1003,7 +1003,7 @@ Namarr_t *nv_setarray(Namval_t *np, void
 		ap->nelem = nelem;
 		ap->fun = fun;
 		nv_onattr(np,NV_ARRAY);
-		if(fp || value)
+		if(fp || (value && value != Empty))
 		{
 			nv_putsub(np, "0", ARRAY_ADD);
 			if(value)