Don't make assumptions about struct members
authorTrent Nelson <trent.a.b.nelson@gmail.com>
Mon, 23 Dec 2013 20:54:06 +0000 (15:54 -0500)
committerace20022 <ace20022@ymail.com>
Tue, 10 Jun 2014 10:21:19 +0000 (12:21 +0200)
This fixes a warning on every file that include StdString.h when
compiling for android and presumably, whichever platform the ifdef was
originally added for.

xbmc/utils/StdString.h

index 34a6b24..12b5550 100644 (file)
@@ -863,11 +863,7 @@ inline const Type& SSMAX(const Type& arg1, const Type& arg2)
       PCSTR pNextSrcA      = pSrcA;
       PWSTR pNextDstW      = pDstW;
       const SSCodeCvt& conv  = SS_USE_FACET(loc, SSCodeCvt);
-#if defined(TARGET_DARWIN) || defined(TARGET_FREEBSD)
-      SSCodeCvt::state_type st= { { 0 } };
-#else
-      SSCodeCvt::state_type st= { 0 };
-#endif
+      SSCodeCvt::state_type st= {};
       SSCodeCvt::result res = conv.in(st,
                               pSrcA, pSrcA + nSrc, pNextSrcA,
                               pDstW, pDstW + nDst, pNextDstW);
@@ -909,11 +905,7 @@ inline const Type& SSMAX(const Type& arg1, const Type& arg2)
       PSTR pNextDstA      = pDstA;
       PCWSTR pNextSrcW    = pSrcW;
       const SSCodeCvt& conv  = SS_USE_FACET(loc, SSCodeCvt);
-#if defined(TARGET_DARWIN) || defined(TARGET_FREEBSD)
-      SSCodeCvt::state_type st= { { 0 } };
-#else
-      SSCodeCvt::state_type st= { 0 };
-#endif
+      SSCodeCvt::state_type st= {};
       SSCodeCvt::result res = conv.out(st,
                               pSrcW, pSrcW + nSrc, pNextSrcW,
                               pDstA, pDstA + nDst, pNextDstA);