diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2011-05-23 22:05:10 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2011-05-23 22:05:10 +0300 |
commit | 7586c955f6e1b4c50614ca59c880369860298134 (patch) | |
tree | 424dc37ee71de5352d340c29738291644073982f /ext.c | |
parent | 57ae4f7df01dc9254912e6b6a71f2602eb8217c5 (diff) | |
download | egawk-7586c955f6e1b4c50614ca59c880369860298134.tar.gz egawk-7586c955f6e1b4c50614ca59c880369860298134.tar.bz2 egawk-7586c955f6e1b4c50614ca59c880369860298134.zip |
Fixes for extension code and tests.
Diffstat (limited to 'ext.c')
-rw-r--r-- | ext.c | 11 |
1 files changed, 9 insertions, 2 deletions
@@ -274,8 +274,15 @@ get_actual_argument(int i, int optional, int want_array) return NULL; } - if (t->type == Node_var_new) - return (want_array ? get_array(t, FALSE) : t); + if (t->type == Node_var_new) { + if (want_array) + return get_array(t, FALSE); + else { + t->type = Node_var; + t->var_value = Nnull_string; + return Nnull_string; + } + } if (want_array) { if (t->type != Node_var_array) |