From: "Wessels, Hans" <H.Wessels@energie-delfland.nl>
To: "'axp-list@redhat.com'" <axp-list@redhat.com>
Subject: RE: Serious warnings from RH 6.1 SRPMs on alpha
Date: Tue, 2 Nov 1999 16:59:43 +0100 [thread overview]
Message-ID: <c=US%a=_%p=delfland%l=MSMAIL-991102155943Z-1471@msmail.energie-delfland.nl> (raw)
>Van: Christian Iseli[SMTP:chris@ludwig-alpha.unil.ch]
>Onderwerp: Re: Serious warnings from RH 6.1 SRPMs on alpha
>
>lucier@math.purdue.edu said:
>> In my (limited) experience, this type of warning almost always
>> indicates that someone is (a) trying to store a pointer in an int
>> variable without (b) knowing that an int is 32 bits and a pointer is
>> 64 bits on alpha linux.
>
>IIRC, this is true to some extent, but not always. For example, one could
>imagine a struct like so:
>struct _foo {
> void *stuff;
>};
>which you would use to pass various data around. If you do things like:
> struct _foo f;
> int bar;
> f.stuff = bar; /* Get a warning */
> ...
> bar = f.stuff; /* Get a warning */
>you should be ok. I'm not saying this is good programming practice BTW ;-)
An other way is:
void foo(char *p)
{
int alignment;
alignment = ((int) p) &0x0F; /* Get a warning */
...
}
Anyone how to do this without getting a warning?
Bye, Hans
----------------------------------------------------------------------
/| /\/\/\ |\ ir. Hans Wessels
/ | / /\/\ \ | \ H.Wessels@Energie-Delfland.nl
/ | / / /\ \ \ | \ tel.: 015 251 4397
/ |/ / / \ \ \| \
\ |\ \ \ / / /| / prive:
\ | \ \ \/ / / | / mr_ni@mbh.org
\ | \ \/\/ / | / Fidelus Bittus et Fuckus Clockcyclus!
\| \/\/\/ |/
**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.
This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.
www.mimesweeper.com
**********************************************************************
next reply other threads:[~1999-11-02 16:01 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-11-02 15:59 Wessels, Hans [this message]
1999-11-02 17:09 ` Serious warnings from RH 6.1 SRPMs on alpha Michal Jaegermann
-- strict thread matches above, loose matches on Subject: below --
1999-11-02 17:18 Brad Lucier
1999-11-02 15:23 Brad Lucier
1999-11-02 15:40 ` Christian Iseli
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