]> granicus.if.org Git - php/commitdiff
Refined fix
authorZeev Suraski <zeev@php.net>
Thu, 11 May 2000 18:49:45 +0000 (18:49 +0000)
committerZeev Suraski <zeev@php.net>
Thu, 11 May 2000 18:49:45 +0000 (18:49 +0000)
Zend/zend_compile.c

index cd393bf379ba3ecc45028512cb53e1ba6438f56a..58b49187cd313f50e9a86fe437cf42e9a5a25747 100644 (file)
@@ -795,11 +795,12 @@ void do_receive_arg(int op, znode *var, znode *offset, znode *initialization, un
                                CG(active_op_array)->arg_types[i] = BYREF_NONE;
                        }
                        CG(active_op_array)->arg_types[0]=(unsigned char) offset->u.constant.value.lval;
+                       CG(active_op_array)->arg_types[offset->u.constant.value.lval] = pass_type;
                }
        } else {
                CG(active_op_array)->arg_types = (unsigned char *) erealloc(CG(active_op_array)->arg_types, sizeof(unsigned char)*(offset->u.constant.value.lval+1));
+               CG(active_op_array)->arg_types[0]=(unsigned char) offset->u.constant.value.lval;
                CG(active_op_array)->arg_types[offset->u.constant.value.lval] = pass_type;
-               CG(active_op_array)->arg_types[0]++;
        }
 }