* [Qemu-devel] block/stream.c -Werror build failure
@ 2013-09-19 16:52 Andreas Färber
2013-09-19 16:59 ` Stefan Weil
0 siblings, 1 reply; 3+ messages in thread
From: Andreas Färber @ 2013-09-19 16:52 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Stefan Weil, Anthony Liguori, Stefan Hajnoczi
Hello,
As reported yesterday on IRC, since the last round of pulls I am getting
the following warning-treated-as-error:
CC block/stream.o
/home/andreas/QEMU/qemu/block/stream.c: In function ‘stream_run’:
/home/andreas/QEMU/qemu/block/stream.c:111:14: error: ‘copy’ may be used
uninitialized in this function [-Werror=maybe-uninitialized]
cc1: all warnings being treated as errors
make: *** [block/stream.o] Fehler 1
$ gcc --version
gcc (SUSE Linux) 4.7.2 20130108 [gcc-4_7-branch revision 195012]
However I only got this in 1 of 2 repositories I tried. It turns out
that --enable-debug avoids this build issue.
The stream.c code itself looks okay to me. In the case of ret >= 0, copy
is always assigned, including the goto code path.
Still, could we initialize the copy variable to false or revert whatever
change introduced this build regression? (-Wextra?)
Regards,
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] block/stream.c -Werror build failure
2013-09-19 16:52 [Qemu-devel] block/stream.c -Werror build failure Andreas Färber
@ 2013-09-19 16:59 ` Stefan Weil
2013-09-19 17:00 ` Andreas Färber
0 siblings, 1 reply; 3+ messages in thread
From: Stefan Weil @ 2013-09-19 16:59 UTC (permalink / raw)
To: Andreas Färber
Cc: Kevin Wolf, Anthony Liguori, qemu-devel, Stefan Hajnoczi
Am 19.09.2013 18:52, schrieb Andreas Färber:
> Hello,
>
> As reported yesterday on IRC, since the last round of pulls I am getting
> the following warning-treated-as-error:
>
> CC block/stream.o
> /home/andreas/QEMU/qemu/block/stream.c: In function ‘stream_run’:
> /home/andreas/QEMU/qemu/block/stream.c:111:14: error: ‘copy’ may be used
> uninitialized in this function [-Werror=maybe-uninitialized]
> cc1: all warnings being treated as errors
> make: *** [block/stream.o] Fehler 1
>
> $ gcc --version
> gcc (SUSE Linux) 4.7.2 20130108 [gcc-4_7-branch revision 195012]
>
> However I only got this in 1 of 2 repositories I tried. It turns out
> that --enable-debug avoids this build issue.
>
> The stream.c code itself looks okay to me. In the case of ret >= 0, copy
> is always assigned, including the goto code path.
> Still, could we initialize the copy variable to false or revert whatever
> change introduced this build regression? (-Wextra?)
>
> Regards,
> Andreas
>
This will be fixed by the next pull request for the block tree.
See also http://patchwork.ozlabs.org/patch/275503/
Regards,
Stefan
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] block/stream.c -Werror build failure
2013-09-19 16:59 ` Stefan Weil
@ 2013-09-19 17:00 ` Andreas Färber
0 siblings, 0 replies; 3+ messages in thread
From: Andreas Färber @ 2013-09-19 17:00 UTC (permalink / raw)
To: Stefan Weil; +Cc: Kevin Wolf, Anthony Liguori, qemu-devel, Stefan Hajnoczi
Am 19.09.2013 18:59, schrieb Stefan Weil:
> Am 19.09.2013 18:52, schrieb Andreas Färber:
>> Hello,
>>
>> As reported yesterday on IRC, since the last round of pulls I am getting
>> the following warning-treated-as-error:
>>
>> CC block/stream.o
>> /home/andreas/QEMU/qemu/block/stream.c: In function ‘stream_run’:
>> /home/andreas/QEMU/qemu/block/stream.c:111:14: error: ‘copy’ may be used
>> uninitialized in this function [-Werror=maybe-uninitialized]
>> cc1: all warnings being treated as errors
>> make: *** [block/stream.o] Fehler 1
>>
>> $ gcc --version
>> gcc (SUSE Linux) 4.7.2 20130108 [gcc-4_7-branch revision 195012]
>>
>> However I only got this in 1 of 2 repositories I tried. It turns out
>> that --enable-debug avoids this build issue.
>>
>> The stream.c code itself looks okay to me. In the case of ret >= 0, copy
>> is always assigned, including the goto code path.
>> Still, could we initialize the copy variable to false or revert whatever
>> change introduced this build regression? (-Wextra?)
>>
>> Regards,
>> Andreas
>>
>
> This will be fixed by the next pull request for the block tree.
> See also http://patchwork.ozlabs.org/patch/275503/
Just spotted it myself and added a review comment.
Thanks,
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-09-19 17:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-19 16:52 [Qemu-devel] block/stream.c -Werror build failure Andreas Färber
2013-09-19 16:59 ` Stefan Weil
2013-09-19 17:00 ` Andreas Färber
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).