From d2f7e788aecf37971c9be1cd650f78a3e4061e18 Mon Sep 17 00:00:00 2001 From: Anthony Green Date: Wed, 14 Mar 2018 09:06:38 -0400 Subject: Fix test cases with short results --- testsuite/libffi.bhaible/test-call.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/testsuite/libffi.bhaible/test-call.c b/testsuite/libffi.bhaible/test-call.c index 4061e70..7dbde10 100644 --- a/testsuite/libffi.bhaible/test-call.c +++ b/testsuite/libffi.bhaible/test-call.c @@ -462,6 +462,7 @@ void /* Unsigned types. */ #ifdef TEST20 + ucr = uc_ucsil(uc1, us2, ui3, ul4); FPRINTF(out,"->%u\n",ucr); fflush(out); ucr = 0; clear_traces(); @@ -470,8 +471,10 @@ void ffi_cif cif; FFI_PREP_CIF(cif,argtypes,ffi_type_uchar); { + ffi_arg rint; /*const*/ void* args[] = { &uc1, &us2, &ui3, &ul4 }; - FFI_CALL(cif,uc_ucsil,args,&ucr); + FFI_CALL(cif,uc_ucsil,args,&rint); + ucr = (uchar) rint; } } FPRINTF(out,"->%u\n",ucr); @@ -562,8 +565,10 @@ void ffi_cif cif; FFI_PREP_CIF(cif,argtypes,ffi_type_ushort); { + ffi_arg rint; /*const*/ void* args[] = { &c1, &d2, &c3, &d4 }; - FFI_CALL(cif,us_cdcd,args,&usr); + FFI_CALL(cif,us_cdcd,args,&rint); + usr = (ushort) rint; } } FPRINTF(out,"->%u\n",usr); -- cgit v1.2.1