diff --git a/src/cc65/pragma.c b/src/cc65/pragma.c index 25bc29d43..64ea4a1aa 100644 --- a/src/cc65/pragma.c +++ b/src/cc65/pragma.c @@ -525,7 +525,7 @@ static void WrappedCallPragma (StrBuf* B) /* Check if the name is valid */ if (Entry && Entry->Flags & SC_FUNC) { - PushWrappedCall(Entry, Val); + PushWrappedCall(Entry, (unsigned char) Val); Entry->Flags |= SC_REF; Entry->V.F.Func->Flags |= FD_CALL_WRAPPER; diff --git a/src/cc65/wrappedcall.c b/src/cc65/wrappedcall.c index 2d11245fd..18cb507ac 100644 --- a/src/cc65/wrappedcall.c +++ b/src/cc65/wrappedcall.c @@ -97,6 +97,6 @@ void GetWrappedCall (void **Ptr, unsigned char *Val) } else { long Temp; IPS_Get (&WrappedCalls, &Temp, Ptr); - *Val = Temp; + *Val = (unsigned char) Temp; } }