From: Michael Roth <mdroth@linux.vnet.ibm.com>
To: Luiz Capitulino <lcapitulino@redhat.com>
Cc: aliguori@us.ibm.com, kraxel@redhat.com, eblake@redhat.com,
qemu-devel@nongnu.org, afaerber@suse.de
Subject: Re: [Qemu-devel] [PATCH 1.1 0/2]: qemu-ga: fix build on openbsd
Date: Wed, 23 May 2012 17:02:39 -0500 [thread overview]
Message-ID: <20120523220239.GB5615@illuin> (raw)
In-Reply-To: <20120523182536.687fcae8@doriath.home>
On Wed, May 23, 2012 at 06:25:36PM -0300, Luiz Capitulino wrote:
> On Wed, 23 May 2012 15:08:43 -0500
> Michael Roth <mdroth@linux.vnet.ibm.com> wrote:
>
> > On Wed, May 23, 2012 at 03:48:03PM -0300, Luiz Capitulino wrote:
> > > Build error found by buildbot:
> > >
> > > qga/commands-posix.c: In function 'qmp_guest_shutdown':
> > > qga/commands-posix.c:65: error: 'environ' undeclared (first use in this function)
> > > qga/commands-posix.c:65: error: (Each undeclared identifier is reported only once
> > > qga/commands-posix.c:65: error: for each function it appears in.)
> > >
> > > On F16 environ is declared in <unistd.h>, but that obviously doesn't
> > > happen on all systems.
> > >
> > > Tested on OpenBSD 4.9.
>
> Just tested on 5.1 too.
>
> > > PS: I get zillions of -Wno-redundant-decls errors on OpenBSD 4.8 and still
> > > get other warnnigs if I drop that flag.
>
> All the -Wno-redundant-decls warnings are still there on 5.1, if I remove that
> flag I still get the following ones. Michael, do you want me to fix the qemu-ga
> one for 1.1?
I'll take a patch, but unless it constitutes a build fix or an actual
overrun I don't think it's worth targetting for 1.1
The sprintf() has been there for a while now so I think it's okay to fix
later since openbsd does seem to have enough coverage to catch qemu-ga
breakages and it hasn't been mentioned yet.
The usage will also be safe for any architecture where pid_t is
defined to be to be 2^64 or less, so we should be good there as well.
>
> LINK qemu-ga
> /usr/local/lib/libglib-2.0.so.2992.0: warning: vsprintf() is often misused, please use vsnprintf()
> /usr/local/lib/libglib-2.0.so.2992.0: warning: stpcpy() is dangerous GNU crap; don't use it
> /usr/local/lib/libglib-2.0.so.2992.0: warning: strcpy() is almost always misused, please use strlcpy()
> qemu-ga.o(.text+0x358): In function `ga_open_pidfile':
> /home/lcapitulino/qmp-unstable/qemu-ga.c:258: warning: sprintf() is often misused, please use snprintf()
>
next prev parent reply other threads:[~2012-05-23 22:02 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-23 18:48 [Qemu-devel] [PATCH 1.1 0/2]: qemu-ga: fix build on openbsd Luiz Capitulino
2012-05-23 18:48 ` [Qemu-devel] [PATCH 1/2] configure: check if environ is declared Luiz Capitulino
2012-05-23 18:48 ` [Qemu-devel] [PATCH 2/2] qemu-ga: Fix missing environ declaration Luiz Capitulino
2012-05-23 20:08 ` [Qemu-devel] [PATCH 1.1 0/2]: qemu-ga: fix build on openbsd Michael Roth
2012-05-23 21:25 ` Luiz Capitulino
2012-05-23 22:02 ` Michael Roth [this message]
2012-05-23 22:15 ` Andreas Färber
2012-05-23 22:57 ` Michael Roth
2012-05-23 23:07 ` Michael Roth
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=20120523220239.GB5615@illuin \
--to=mdroth@linux.vnet.ibm.com \
--cc=afaerber@suse.de \
--cc=aliguori@us.ibm.com \
--cc=eblake@redhat.com \
--cc=kraxel@redhat.com \
--cc=lcapitulino@redhat.com \
--cc=qemu-devel@nongnu.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.