[Libreoffice-commits] core.git: vcl/unx

Stephan Bergmann sbergman at redhat.com
Wed Jan 24 12:18:22 UTC 2018


 vcl/unx/generic/app/saldisp.cxx |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit dc9e271c130a14e1f8446227238397ddcb34028a
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Tue Jan 23 12:30:24 2018 +0100

    Use a more conventional way of zero-initializing class members
    
    ...to avoid upcoming GCC 8 -Werror=class-memaccess ("clearing an object of non-
    trivial type ‘class SalVisual’")
    
    Change-Id: Id9c5a6fa7e084b5abd549c99d07f05f183d56a52
    Reviewed-on: https://gerrit.libreoffice.org/48402
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/vcl/unx/generic/app/saldisp.cxx b/vcl/unx/generic/app/saldisp.cxx
index 767cf81aa239..edf8ca53246f 100644
--- a/vcl/unx/generic/app/saldisp.cxx
+++ b/vcl/unx/generic/app/saldisp.cxx
@@ -2374,10 +2374,10 @@ bool SalDisplay::XIfEventWithTimeout( XEvent* o_pEvent, XPointer i_pPredicateDat
     return bRet;
 }
 
-SalVisual::SalVisual()
-{
-    memset( this, 0, sizeof( SalVisual ) );
-}
+SalVisual::SalVisual():
+    eRGBMode_(RGB), nRedShift_(0), nGreenShift_(0), nBlueShift_(0), nRedBits_(0), nGreenBits_(0),
+    nBlueBits_(0)
+{}
 
 SalVisual::SalVisual( const XVisualInfo* pXVI )
 {


More information about the Libreoffice-commits mailing list