Fix SVACE errors 19/193519/1
authorAdeel Kazmi <adeel.kazmi@samsung.com>
Wed, 21 Nov 2018 11:25:24 +0000 (11:25 +0000)
committerAdeel Kazmi <adeel.kazmi@samsung.com>
Wed, 21 Nov 2018 11:25:42 +0000 (11:25 +0000)
Change-Id: I33483d4b9c3204def03a5301c4e0775463bca716

dali/internal/adaptor/common/adaptor-impl.cpp
dali/internal/window-system/common/window-render-surface.cpp
dali/internal/window-system/ubuntu-x11/pixmap-render-surface-ecore-x.cpp

index 629a30e..05b60f9 100755 (executable)
@@ -160,6 +160,9 @@ void Adaptor::Initialize( GraphicsFactory& graphicsFactory, Dali::Configuration:
   mCallbackManager = CallbackManager::New();
 
   WindowPane defaultWindow = mWindowFrame.front();
+
+  DALI_ASSERT_DEBUG( defaultWindow.surface && "Surface not initialized" );
+
   PositionSize size = defaultWindow.surface->GetPositionSize();
 
   mGestureManager = new GestureManager(*this, Vector2(size.width, size.height), mCallbackManager, *mEnvironmentOptions);
@@ -192,14 +195,7 @@ void Adaptor::Initialize( GraphicsFactory& graphicsFactory, Dali::Configuration:
 
   mVSyncMonitor = new VSyncMonitor;
 
-  if( defaultWindow.surface )
-  {
-    mDisplayConnection = Dali::DisplayConnection::New( *mGraphics, defaultWindow.surface->GetSurfaceType() );
-  }
-  else
-  {
-    mDisplayConnection = Dali::DisplayConnection::New( *mGraphics );
-  }
+  mDisplayConnection = Dali::DisplayConnection::New( *mGraphics, defaultWindow.surface->GetSurfaceType() );
 
   mThreadController = new ThreadController( *this, *mEnvironmentOptions );
 
@@ -972,7 +968,9 @@ Adaptor::Adaptor(Any nativeWindow, Dali::Adaptor& adaptor, RenderSurface* surfac
   mCore( nullptr ),
   mThreadController( nullptr ),
   mVSyncMonitor( nullptr ),
+  mGraphics( nullptr ),
   mDisplayConnection( nullptr ),
+  mWindowFrame(),
   mPlatformAbstraction( nullptr ),
   mEventHandler( nullptr ),
   mCallbackManager( nullptr ),
index c29c861..2727430 100644 (file)
@@ -57,6 +57,7 @@ WindowRenderSurface::WindowRenderSurface( Dali::PositionSize positionSize, Any s
   mThreadSynchronization( NULL ),
   mRenderNotification( NULL ),
   mRotationTrigger( NULL ),
+  mGraphics( nullptr ),
   mColorDepth( isTransparent ? COLOR_DEPTH_32 : COLOR_DEPTH_24 ),
   mOutputTransformedSignal(),
   mRotationAngle( 0 ),
index bd31ff8..03259eb 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2018 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -55,13 +55,18 @@ static const int INITIAL_CONSUME_BUFFER_INDEX = 1;
 }
 
 PixmapRenderSurfaceEcoreX::PixmapRenderSurfaceEcoreX( Dali::PositionSize positionSize, Any surface, bool isTransparent )
-: mPosition( positionSize ),
+: mGraphics( nullptr ),
+  mDisplayConnection( nullptr ),
+  mPosition( positionSize ),
   mRenderNotification( NULL ),
   mColorDepth( isTransparent ? COLOR_DEPTH_32 : COLOR_DEPTH_24 ),
   mOwnSurface( false ),
   mProduceBufferIndex( INITIAL_PRODUCE_BUFFER_INDEX ),
   mConsumeBufferIndex( INITIAL_CONSUME_BUFFER_INDEX ),
-  mThreadSynchronization(NULL)
+  mX11Pixmaps(),
+  mEglSurfaces(),
+  mThreadSynchronization( nullptr ),
+  mPixmapCondition()
 {
   for( int i = 0; i != BUFFER_COUNT; ++i )
   {