mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-02-15 04:32:24 +00:00
nv_associative(): clarify value indicating enum (re: 6b9703ff
)
This commit is contained in:
parent
e554a07c56
commit
893c6a9068
1 changed files with 2 additions and 3 deletions
|
@ -1777,12 +1777,11 @@ void *nv_associative(register Namval_t *np,const char *sp,int mode)
|
|||
if(sh.subshell)
|
||||
np = sh_assignok(np,1);
|
||||
/*
|
||||
* type == 0x26 == NV_INTEGER|NV_LTOU|NV_RJUST (see include/nval.h) indicates an
|
||||
* type == NV_UINT16 (16-bit unsigned integer, see include/nval.h) indicates an
|
||||
* associative array of a type created by the enum command. nelem should not be
|
||||
* increased in that case or 'unset' will fail to completely unset such an array.
|
||||
*/
|
||||
if(type != (NV_INTEGER|NV_LTOU|NV_RJUST)
|
||||
&& (!ap->header.scope || !nv_search(sp,dtvnext(ap->header.table),0)))
|
||||
if(type != NV_UINT16 && (!ap->header.scope || !nv_search(sp,dtvnext(ap->header.table),0)))
|
||||
ap->header.nelem++;
|
||||
if(nv_isnull(mp))
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue