From: Marcel Holtmann <marcel@holtmann.org>
To: ofono@ofono.org
Subject: Re: [PATCH] Fix: transaction id usage in gisi/server.c
Date: Fri, 23 Apr 2010 16:34:44 +0200 [thread overview]
Message-ID: <1272033284.22838.81.camel@localhost.localdomain> (raw)
In-Reply-To: <0f719e09b0048c8e277f38b1937eeb11@chewa.net>
[-- Attachment #1: Type: text/plain, Size: 1668 bytes --]
Hi Remi,
> >> Casting to or from void is not necessary.
> >
> > Oh, it is. If a struct sockaddr_pn structure is casted directly to
> > struct sockaddr, gcc will issue alignment warning on ARM.
>
> The cast-align warning is a can of false positives. First that warning
> should probably not be enabled. It does nothing on x86, and it's a waste of
> time with ARM and other pointer-picky platforms.
I don't have an ARM platform easy available to test this, but this can
be fixed by just memcpy the data structures.
> Most importantly, using -Werror _by_default_ is a _damn_idiotic_ idea. Been
> there, done that. One cannot know what weird warning any given compiler or
> version thereof will ever return. And then I don't need to mention "bugs"
> in header files from underlying components. Even changing GCC optimization
> levels can yield different conflicting warnings. That's known to happen for
> uninitialized values detection, which relies on optimization-dependent code
> analysis as an example.
The rant about -Werror doesn't help. We are using it to catch nasty
constructs that might fail on any given platform. We have used -Werror
inside BlueZ and ConnMan for a long time now. Yes, sometimes new GCC
warnings come up and we fix that, but it was always good to have these.
And yes, it is true that you need to use -O2 to enable a bunch of these
warnings.
So in conclusion, the -Werror stays and we need to fix the code to
compile cleanly on any given platform. It is possible, so lets get this
done. Feel free to post the warnings on the mailing list and I am more
than happy to look into it.
Regards
Marcel
next prev parent reply other threads:[~2010-04-23 14:34 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-22 11:26 [PATCH] Fix: transaction id usage in gisi/server.c Pekka Pessi
2010-04-22 21:27 ` Denis Kenzior
2010-04-22 21:32 ` Denis Kenzior
2010-04-23 13:07 ` Pekka Pessi
2010-04-23 13:46 ` =?unknown-8bit?q?R=C3=A9mi?= Denis-Courmont
2010-04-23 14:34 ` Marcel Holtmann [this message]
2010-04-23 14:57 ` Pekka Pessi
-- strict thread matches above, loose matches on Subject: below --
2010-04-23 15:15 =?unknown-8bit?q?R=C3=A9mi?= Denis-Courmont
2010-04-23 15:17 Pekka Pessi
2010-04-23 15:27 ` =?unknown-8bit?q?R=C3=A9mi?= Denis-Courmont
2010-04-23 17:43 ` Denis Kenzior
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1272033284.22838.81.camel@localhost.localdomain \
--to=marcel@holtmann.org \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.