Search
SailfishOS Open Build Service
>
Projects
>
home:jacky_lau
>
qpa-eglfs
> 001-eglfs-fixing-memory-leaking.patch
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File 001-eglfs-fixing-memory-leaking.patch of Package qpa-eglfs
diff -ru qt5-plugin-platform-eglfs-5.0.2/eglfs.pro qt5-plugin-platform-eglfs-5.0.2-modify/eglfs.pro --- qt5-plugin-platform-eglfs-5.0.2/eglfs.pro 2013-09-03 19:07:17.000000000 +0800 +++ qt5-plugin-platform-eglfs-5.0.2-modify/eglfs.pro 2013-09-03 19:20:49.762313037 +0800 @@ -43,6 +43,8 @@ DEFINES += EGLFS_PLATFORM_HOOKS } +LIBS += -ludev -lmtdev -lglib-2.0 + CONFIG += egl qpa/genericunixfontdatabase RESOURCES += cursor.qrc diff -ru qt5-plugin-platform-eglfs-5.0.2/qeglfswindow.cpp qt5-plugin-platform-eglfs-5.0.2-modify/qeglfswindow.cpp --- qt5-plugin-platform-eglfs-5.0.2/qeglfswindow.cpp 2013-09-03 19:07:17.000000000 +0800 +++ qt5-plugin-platform-eglfs-5.0.2-modify/qeglfswindow.cpp 2013-09-03 19:17:55.902318539 +0800 @@ -72,7 +72,7 @@ void QEglFSWindow::create() { - if (m_window) + if (m_surface != EGL_NO_SURFACE) return; if (window()->type() == Qt::Desktop) { @@ -92,6 +92,9 @@ EGLint error = eglGetError(); eglTerminate(display); qFatal("EGL Error : Could not create the egl surface: error = 0x%x\n", error); + + hooks->destroyNativeWindow(m_window); + m_window = 0; } }