From: "Lagodzinski, Andrew" <ANDREW.LAGODZINSKI@kla-tencor.com>
To: axp-list@redhat.com
Subject: RE: So Y is my pointer so bogus
Date: Wed, 3 Feb 1999 14:57:57 -0800 [thread overview]
Message-ID: <C3512DB43868D111AAF400A0C91110790134025F@milxpr02.kla-tencor.com> (raw)
try this:
a = ((int *)a) +(x2-x1-x3)*P + (y2-y1-y3)*S;
Not the extra parens around (int*)a.
> -----Original Message-----
> From: Uncle George [mailto:gatgul@voicenet.com]
> Sent: Wednesday, February 03, 1999 2:36 PM
> To: axp-list@redhat.com
> Cc: recipient list not shown;
> @redhat.com@kla-tencor.com@kla-tencor.com@kla-tencor.com
> Subject: So Y is my pointer so bogus
>
>
> This little example caused a (un-expected ) pointer failure in one of
> the font routines in my java 1.2 port on linux/alpha. It was
> expected to
> add a -1760 ( -1760 * sizeof(int)) but does not.
> Ugg. what is a 64bitter to do.
> gat
> main()
> {
>
> int x1,x2,x3;
> int y1,y2,y3;
> unsigned int P;
> unsigned int S;
> void *a;
>
> a = (void *)0;
> x1=20,x2=0,x3=0;
> y1=5, y2=0,y3=0;
> P = 1;
> S = 348;
>
> a = (int *)a +(x2-x1-x3)*P + (y2-y1-y3)*S;
> printf("a = %p\n",a);
> }
>
>
>
>
>
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
>
next reply other threads:[~1999-02-03 23:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-02-03 22:57 Lagodzinski, Andrew [this message]
-- strict thread matches above, loose matches on Subject: below --
1999-02-03 22:36 So Y is my pointer so bogus Uncle George
1999-02-03 22:59 ` Jason Duerstock
1999-02-03 23:32 ` B. James Phillippe
1999-02-03 23:45 ` Uncle George
1999-02-04 0:51 ` Michal Jaegermann
1999-02-04 0:55 ` Michal Jaegermann
1999-02-03 23:36 ` Uncle George
1999-02-04 0:38 ` Michal Jaegermann
1999-02-04 11:25 ` Phil Carmody
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox