Bug fix: copied wrong size to destination in structure returns
authorceriel <none@none>
Tue, 1 Jul 1997 08:33:13 +0000 (08:33 +0000)
committerceriel <none@none>
Tue, 1 Jul 1997 08:33:13 +0000 (08:33 +0000)
lang/cem/cemcom.ansi/code.c
lang/cem/cemcom/code.c

index e16ae47..1f969bf 100644 (file)
@@ -412,7 +412,7 @@ do_return_expr(expr)
        code_expr(expr, RVAL, TRUE, NO_LABEL, NO_LABEL);
        if (struct_return != 0) {
                LoadLocal((arith) 0, pointer_size);
-               store_block(func_size, func_type->tp_align);
+               store_block(func_type->tp_size, func_type->tp_align);
        }
        C_bra(return_label);
        return_expr_occurred = 1;
index eda7b20..d82b8da 100644 (file)
@@ -319,7 +319,7 @@ end_proc(fbytes)
        if (return_expr_occurred) {
                if (func_res_label != 0)        {
                        C_lae_dlb(func_res_label, (arith)0);
-                       store_block(func_size, func_type->tp_align);
+                       store_block(func_type->tp_size, func_type->tp_align);
                        C_lae_dlb(func_res_label, (arith)0);
                        C_ret(pointer_size);
                }