From 7e37fd35471bf41ae7b9ab8c2f91904a56282f05 Mon Sep 17 00:00:00 2001 From: Matt Ellis Date: Fri, 25 Sep 2015 17:18:34 -0700 Subject: [PATCH] Fix clang only build breaks Some new code from TFS was triggering this error in clang: `error: suggest braces around initialization of subobject` I just made the obvious fix. Commit migrated from https://github.com/dotnet/coreclr/commit/bc966c6018f2e0e467d56fda62f2cbdaa63d0173 --- src/coreclr/src/vm/ceeload.cpp | 2 +- src/coreclr/src/vm/securitymeta.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/coreclr/src/vm/ceeload.cpp b/src/coreclr/src/vm/ceeload.cpp index 714547b..d3d5bb8 100644 --- a/src/coreclr/src/vm/ceeload.cpp +++ b/src/coreclr/src/vm/ceeload.cpp @@ -3068,7 +3068,7 @@ BOOL Module::IsRuntimeWrapExceptions() if (hr == S_OK) { CustomAttributeParser ca(pVal, cbVal); - CaNamedArg namedArgs[1] = {0}; + CaNamedArg namedArgs[1] = {{0}}; // First, the void constructor: IfFailGo(ParseKnownCaArgs(ca, NULL, 0)); diff --git a/src/coreclr/src/vm/securitymeta.cpp b/src/coreclr/src/vm/securitymeta.cpp index 9c7e447..9ab6dbe 100644 --- a/src/coreclr/src/vm/securitymeta.cpp +++ b/src/coreclr/src/vm/securitymeta.cpp @@ -1834,7 +1834,7 @@ TokenSecurityDescriptorFlags ParseAptcaAttribute(const BYTE *pbAptcaBlob, DWORD aptcaFlags |= TokenSecurityDescriptorFlags_APTCA; // Look for the PartialTrustVisibilityLevel named argument - CaNamedArg namedArgs[1] = {0}; + CaNamedArg namedArgs[1] = {{0}}; namedArgs[0].InitI4FieldEnum(g_PartialTrustVisibilityLevel, g_SecurityPartialTrustVisibilityLevel); if (SUCCEEDED(ParseKnownCaNamedArgs(cap, namedArgs, _countof(namedArgs)))) -- 2.7.4