Article View: comp.sys.amiga.tech
Article #3254YAMB (Yet Another Manx Bug in 5.0a)
From: Stephen Steir
Date: Wed, 11 Apr 1990 12:17
Date: Wed, 11 Apr 1990 12:17
31 lines
1350 bytes
1350 bytes
I post this example in hopes that it will save time for other Manx 5.0a users.
Compile the following program with large code and data -mcd.
int foo(a, b, c)
short a, b, c;
{
printf("a = %d b = %d c = %d\n", a, b, c);
}
main()
{
int (*p2foo)();
short a, b, c;
a = 1;
b = 2;
c = 3;
p2foo = foo;
(*p2foo)(a, b, c);
}
You will notice that a, b and c get pushed on the stack incorrectly as
longs yet foo will still unwrap a, b, and c correctly as shorts. When run,
foo prints a = 1 b = 0 c = 2.
This bug has been reported and Manx says that it will be fixed in the next
release.
------------------------------------------------------------------------------
Steve Steir - Clearpoint Research Corp., 35 Parkwood Dr., Hopkinton, Ma. 01748
UUCP: steve@frog!cpoint ATT: (508) 435-2000 BIX: clearpoint
------------------------------------------------------------------------------
Technical Details
Message-ID:
<4606@cpoint.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!attcan!uunet!tut.cis.ohio-state.edu!ucbvax!bloom-beacon!bu.edu!xylogics!transfer!lectroid!jjmhome!cpoint!steveShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!tut.cis.ohio-state.edu!ucbvax!bloom-beacon!bu.edu!xylogics!transfer!lectroid!jjmhome!cpoint!steve From: steve@cpoint.UUCP (Stephen Steir) Newsgroups: comp.sys.amiga.tech Subject: YAMB (Yet Another Manx Bug in 5.0a) Message-ID: <4606@cpoint.UUCP> Date: 11 Apr 90 12:17:13 GMT Reply-To: steve@cpoint.UUCP (Stephen Steir) Organization: Clearpoint Research Corp., Hopkinton Mass. Lines: 31