mirror of https://github.com/acidanthera/audk.git
StdLib/LibC/gdtoa: fix "missing braces around initializer"
The member "u.L" is an array, and the current initializer triggers StdLib/LibC/gdtoa/strtof.c: In function '_strtof': StdLib/LibC/gdtoa/strtof.c:53:9: error: missing braces around initializer [-Werror=missing-braces] StdLib/LibC/gdtoa/strtof.c:53:9: error: (near initialization for 'u.L') [-Werror=missing-braces] cc1: all warnings being treated as errors Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15785 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
1be8039054
commit
599aa11f87
|
@ -50,7 +50,7 @@ strtof(CONST char *s, char **sp)
|
|||
ULong bits[1];
|
||||
Long expt;
|
||||
int k;
|
||||
union { ULong L[1]; float f; } u = { 0 };
|
||||
union { ULong L[1]; float f; } u = { { 0 } };
|
||||
|
||||
k = strtodg(s, sp, &fpi, &expt, bits);
|
||||
if (k == STRTOG_NoMemory) {
|
||||
|
|
Loading…
Reference in New Issue