<div dir="auto">Thank you so much for the replies. I appreciate the effort, time, and detail.<div dir="auto"><div dir="auto"><br></div><div dir="auto">Turns out the warning is created by: </div><div dir="auto">-Wextra</div><div dir="auto"><br></div><div dir="auto">Only occurs in the older compiler (which we are required to use). </div><div dir="auto"><br></div><div dir="auto">Removing the compiler flag worked. </div><div dir="auto"><br></div><div dir="auto">Thanks again,</div><div dir="auto">Mike</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jun 25, 2020, 9:42 AM Michael Wojcik <<a href="mailto:Michael.Wojcik@microfocus.com">Michael.Wojcik@microfocus.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">> From: openssl-users [mailto:<a href="mailto:openssl-users-bounces@openssl.org" target="_blank" rel="noreferrer">openssl-users-bounces@openssl.org</a>] On Behalf Of<br>
> Matt Caswell<br>
> Sent: Thursday, June 25, 2020 04:51<br>
><br>
> On 24/06/2020 20:20, Michael Mueller wrote:<br>
> ><br>
> > Questions<br>
> ><br>
> > 1. Is the fix valid?<br>
><br>
> Seems ok, but it looks like the compiler warning is a bit over zealous.<br>
<br>
It's valid, but I'd argue it's not a "fix".<br>
<br>
As Rich Salz pointed out, omitting initializers is permitted by the C standard. In fact it's endorsed, in the sense that the standard makes this behavior explicit (see e.g. ISO 9899-1999 6.7.8 #21 for arrays, or in the case of subobjects #19), and the Rationale (I'm referring to 5.10, published 2003) does not discourage its use, as it does for e.g. omitting braces for compound object initializers and relying on the mandated top-down-parse semantics.<br>
<br>
In his monumental /The New C Standard: An Economic and Cultural Commentary/ (2005), Derek M. Jones comments on this aspect of the language by noting some costs involved in requiring all members be explicitly initialized, and concludes: " Given these costs and the fact that developers are generally aware of the default behavior, there does not appear to be a worthwhile benefit in a guideline recommending that the behavior be made explicit." (1669) The GCC developers (like all C implementors) would have done well to read Jones.<br>
<br>
> We have the same pattern in many parts of the code I think without problems.<br>
<br>
Yes, as it should be.<br>
<br>
> > 2.  If fix is valid, what are the chances of getting the change accepted?<br>
><br>
> Doubtful.<br>
<br>
And I'd say that's appropriate. Some of the GCC developers would prefer programmers use a language which is similar to, but distinctly not C, eschewing useful constructs and employing various others which are not part of the C language. OpenSSL is written in C.<br>
<br>
--<br>
Michael Wojcik<br>
Distinguished Engineer, Micro Focus<br>
<br>
</blockquote></div>