Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Backport ksh93v- bugfix for a possible crash in types.sh (#812)
This commit backports a bugfix from ksh93v- 2012-08-24 for a possible crash at the first strncmp in create_type(). This crash will occur if the size and/or alignment of Namval struct is changed (i.e., if np->nvsize or np->nvflag is upgraded to a larger data type). src/cmd/ksh93/sh/nvtype.c: - Account for NV_MINSZ when setting the 'base' string to ensure no invalid reads occur because of changes in the size of Namval_t. - Additionally, store the return value from strlen in a size_t variable.
- Loading branch information