[PATCH] mostly clang warnings

Volker Lendecke vl at samba.org
Wed Oct 19 09:10:07 UTC 2016


Jeremy Allison <jra at samba.org> writes:

> On Tue, Oct 18, 2016 at 11:18:48AM -0700, Jeremy Allison wrote:
> Bah. The initializer fix patchset fails due to
> bugs in gcc 4.8.x (which we use on sn-devel).
>
> struct smb2_handle foo = { 0 }
>
> gives:
>
> error: missing braces around initializer [-Werror=missing-braces]
>
> because gcc 4.8.x doesn't understand the { 0 }
> as initializing the array.
>
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53119
>
> Using:
>
> struct smb2_handle foo = {{ 0 }};
>
> works, but is really ugly :-(.

Builds on sn-devel as well as on clang. Attached.

Review appreciated!

Thanks, Volker


-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch.txt
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20161019/f2840ddd/patch.txt>


More information about the samba-technical mailing list