Re: [PATCH] qemu: tpm: Initialize variable with NULL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/8/21 3:50 PM, Stefan Berger wrote:
> 
> On 11/8/21 09:40, Ján Tomko wrote:
>> On a Monday in 2021, Marc-André Lureau wrote:
>>> On Mon, Nov 8, 2021 at 5:53 PM Stefan Berger <stefanb@xxxxxxxxxxxxx>
>>> wrote:
>>>>
>>>> Initialize an autofree'd variable with NULL that causes crashes
>>>> if a TPM 1.2 is used and the variable doesn't get a value assigned.
>>>>
>>>> Signed-off-by: Stefan Berger <stefanb@xxxxxxxxxxxxx>
>>>
>>> certainly, I wished there would be a gcc error there..
>>>
>>
>> There was
>> https://gitlab.com/libvirt/libvirt/-/pipelines/402739013/failures
>>
>> And this was already patched by Peter:
>> commit c43f22d5c1ea08c5516d791010ed3c230c47cb53
>>     qemuTPMEmulatorReconfigure: Fix two build issues
> 
> Sorry for the noise. F34 gcc hadn't complained.
> 

I've noticed that some of these warnings fire only when compiling with
-O2. Since I'm debugging a lot I'm in habit of setting -O0 -ggdb. And
that's when gcc did not emit the warning.

Michal




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux