From 63f0fcb5d6b33b85812cf867057862064731b4b8 Mon Sep 17 00:00:00 2001 From: Andrew den Exter Date: Wed, 17 Apr 2013 15:13:56 +1000 Subject: Fix crash on idle status change with 64 bit architectures. bool and gboolean are not necessarily the same size on all architectures, and if gboolean is larger than bool then passing it as an argument to g_object_get can trash the stack. In this case overwriting some of the session pointer. Change-Id: Iaa7be6a327e9f69212bd7d5bb372d33f2026db0f Reviewed-by: Andy Nichols --- src/plugins/gstreamer/camerabin/camerabinsession.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/plugins/gstreamer/camerabin/camerabinsession.cpp b/src/plugins/gstreamer/camerabin/camerabinsession.cpp index f58bea205..2e5c53a4d 100644 --- a/src/plugins/gstreamer/camerabin/camerabinsession.cpp +++ b/src/plugins/gstreamer/camerabin/camerabinsession.cpp @@ -672,7 +672,7 @@ void CameraBinSession::updateBusyStatus(GObject *o, GParamSpec *p, gpointer d) Q_UNUSED(p); CameraBinSession *session = reinterpret_cast(d); - bool idle = false; + gboolean idle = false; g_object_get(o, "idle", &idle, NULL); bool busy = !idle; -- cgit v1.2.3