Hi Laszlo,

I understand it is wrong. Anyway, here is the patch with that fix.

About the subscription, I am testing the WinDDK 7.1
(http://www.microsoft.com/en-us/download/details.aspx?id=11800) and so
far, so good, I guess you can give it a try, I can even send the
tools_def.txt with the changes I made to make it work, I am not sure
about its licensing yet, but my guess is that it can be used for these
means.

I don't remember were, but I read that someone got it to work with
wine, whenever I have some time I'll try to make it work as well.

Cheers,

On Wed, Feb 5, 2014 at 5:39 PM, Laszlo Ersek <[email protected]> wrote:
> On 02/05/14 20:28, Mauro Faccenda wrote:
>> Hi all,
>>
>> When trying to compile OVMF in latest version it fails with the following 
>> error:
>>
>> edk2\ovmfpkg\library\platformbdslib\qemubootorder.c(888) : warning
>> C4701: potentially uninitialized local variable 'IsFinal' used.
>>
>> The IsFinal variable should be initialized (assume FALSE?).
>
> No, MSVC is wrong.
>
> I added some new code in SVN r15197, and MSVC fails to see that the
> place where isFinal is used is never reached when isFinal is not set.
>
> MSVC is driving me nuts, honestly. I'm tired of babysitting it. If you
> send a patch, initializing IsFinal to whatever value, I'll ack it
> though. Also, in any new code I write I'll initialize block scope
> variables inside their definitions, no matter how match that clashes
> with the coding style. This warning crap is ridiculous. Should I ask Red
> Hat to shell out $$$ for an MSDN subscription for me, just to shut up
> these warnings? Also, should I ask for four versions of MSVC so that I
> can be sure each one of them is silenced appropriately? Please.
>
> If you look at SVN r15197, you're gonna notice that the
>
>   NumNodes = 0;
>
> assignment *also* could have been moved under the "else" branch. Because
> NumNodes is never used if we take the other branch. But, I intentionally
> left the assignment in place, because I was sure that MSVC would
> complain if I had made the assignment conditional. Looks like you can
> never be paranoid enough.
>
> Laszlo

Attachment: babysitting_msvc_isfinal.patch
Description: Binary data

------------------------------------------------------------------------------
Managing the Performance of Cloud-Based Applications
Take advantage of what the Cloud has to offer - Avoid Common Pitfalls.
Read the Whitepaper.
http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to