summaryrefslogtreecommitdiffstats
path: root/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
diff options
context:
space:
mode:
authorJohan Klokkhammer Helsing <johan.helsing@qt.io>2018-02-27 16:21:17 +0100
committerJohan Helsing <johan.helsing@qt.io>2018-02-28 10:51:35 +0000
commit1fab644753443a525475740fc23172dedaa70d0e (patch)
treebca0a88662679acd150172f5a73f64d1604960cf /src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
parentc4bd9198b4a0fac809903dd2c09276c2c3c1b22e (diff)
Use default member initialization for raw pointers
Initialize to nullptr to prevent undefined behavior. Change-Id: I7753c0be77a886d62ecb1cd7b86fc8c98340b0b8 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Diffstat (limited to 'src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp')
-rw-r--r--src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
index 740ad6b1..740e9641 100644
--- a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
+++ b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
@@ -219,8 +219,8 @@ public:
m_blitProgram->disableAttributeArray(1);
}
- QOpenGLShaderProgram *m_blitProgram;
- QWaylandGLContext *m_context;
+ QOpenGLShaderProgram *m_blitProgram = nullptr;
+ QWaylandGLContext *m_context = nullptr;
};
@@ -512,7 +512,7 @@ private:
GLint stride;
GLenum type;
bool normalized;
- void *pointer;
+ void *pointer = nullptr;
} m_vertexAttribs[STATE_GUARD_VERTEX_ATTRIB_COUNT];
GLenum m_minFilter;
GLenum m_magFilter;