From 2cac0f114247a29fba32510c4c0ea549c8c0a7c9 Mon Sep 17 00:00:00 2001 From: Toomas Soome Date: Tue, 27 Nov 2018 11:40:19 +0200 Subject: 12106 libshell: cast between incompatible function types Reviewed by: John Levon Approved by: Robert Mustacchi --- usr/src/lib/libshell/common/sh/streval.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'usr/src/lib/libshell/common') diff --git a/usr/src/lib/libshell/common/sh/streval.c b/usr/src/lib/libshell/common/sh/streval.c index 2b7a677f68..11df8402e8 100644 --- a/usr/src/lib/libshell/common/sh/streval.c +++ b/usr/src/lib/libshell/common/sh/streval.c @@ -391,7 +391,7 @@ Sfdouble_t arith_exec(Arith_t *ep) sp--,tp--; fun = *((Math_f*)(ep->code+(int)(*sp))); type = *tp; - num = (*((Math_1i_f)fun))(num); + num = (*((Math_1i_f)(uintptr_t)fun))(num); break; case A_CALL2F: sp-=2,tp-=2; @@ -403,7 +403,7 @@ Sfdouble_t arith_exec(Arith_t *ep) sp-=2,tp-=2; fun = *((Math_f*)(ep->code+(int)(*sp))); type = *tp; - num = (*((Math_2i_f)fun))(sp[1],num); + num = (*((Math_2i_f)(uintptr_t)fun))(sp[1],num); break; case A_CALL3F: sp-=3,tp-=3; -- cgit v1.2.3