summaryrefslogtreecommitdiffstats
path: root/src/plugins/gfxdrivers/directfb
diff options
context:
space:
mode:
authorAnders Bakken <anders.bakken@nokia.com>2010-02-24 22:12:11 (GMT)
committerAnders Bakken <anders.bakken@nokia.com>2010-02-24 22:17:00 (GMT)
commit4ae8ab9d7ce2cde5c798f13a7bccf05976eb5d54 (patch)
tree80db52f17eacb96bcaebcd50fcda403adba827e4 /src/plugins/gfxdrivers/directfb
parentdda020241665f895ff4587ca6a08b7bf65c046bf (diff)
downloadQt-4ae8ab9d7ce2cde5c798f13a7bccf05976eb5d54.zip
Qt-4ae8ab9d7ce2cde5c798f13a7bccf05976eb5d54.tar.gz
Qt-4ae8ab9d7ce2cde5c798f13a7bccf05976eb5d54.tar.bz2
Initialize mem to 0
If DirectFB fails to lock a surface it won't necessarily set mem to 0. Reviewed-by: Jervey Kong <jervey.kong@nokia.com>
Diffstat (limited to 'src/plugins/gfxdrivers/directfb')
-rw-r--r--src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp b/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp
index ff997c0..cffd4e3 100644
--- a/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp
+++ b/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp
@@ -1680,7 +1680,7 @@ bool QDirectFBScreen::initSurfaceDescriptionPixelFormat(DFBSurfaceDescription *d
uchar *QDirectFBScreen::lockSurface(IDirectFBSurface *surface, DFBSurfaceLockFlags flags, int *bpl)
{
- void *mem;
+ void *mem = 0;
const DFBResult result = surface->Lock(surface, flags, &mem, bpl);
if (result != DFB_OK) {
DirectFBError("QDirectFBScreen::lockSurface()", result);