From 41a0bfaf7c932b8e1e68249810ce5ec3b3245154 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 1 Aug 2009 09:07:45 +0000 Subject: sizeof() was being used incorrectly to clear X11 m_keyboard_vector, would only have 4-8 bytes cleared rather then 32. fix for harmless memleak too. --- intern/ghost/intern/GHOST_SystemX11.cpp | 8 +++----- intern/ghost/intern/GHOST_SystemX11.h | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'intern') diff --git a/intern/ghost/intern/GHOST_SystemX11.cpp b/intern/ghost/intern/GHOST_SystemX11.cpp index e7e47a6bf38..25e60002de0 100644 --- a/intern/ghost/intern/GHOST_SystemX11.cpp +++ b/intern/ghost/intern/GHOST_SystemX11.cpp @@ -145,11 +145,9 @@ init( GHOST_TSuccess success = GHOST_System::init(); if (success) { - m_keyboard_vector = new char[32]; - m_displayManager = new GHOST_DisplayManagerX11(this); - if (m_keyboard_vector && m_displayManager) { + if (m_displayManager) { return GHOST_kSuccess; } } @@ -672,9 +670,9 @@ getModifierKeys( // analyse the masks retuned from XQueryPointer. - memset(m_keyboard_vector,0,sizeof(m_keyboard_vector)); + memset((void *)m_keyboard_vector,0,sizeof(m_keyboard_vector)); - XQueryKeymap(m_display,m_keyboard_vector); + XQueryKeymap(m_display,(char *)m_keyboard_vector); // now translate key symobols into keycodes and // test with vector. diff --git a/intern/ghost/intern/GHOST_SystemX11.h b/intern/ghost/intern/GHOST_SystemX11.h index 6a2c81c09a7..58017bd2392 100644 --- a/intern/ghost/intern/GHOST_SystemX11.h +++ b/intern/ghost/intern/GHOST_SystemX11.h @@ -246,7 +246,7 @@ private : GHOST_TUns64 m_start_time; /// A vector of keyboard key masks - char *m_keyboard_vector; + char m_keyboard_vector[32]; /** * Return the ghost window associated with the -- cgit v1.2.3 From b6abeca2fede580ec02cb3221258f39ba982d205 Mon Sep 17 00:00:00 2001 From: Benoit Bolsee Date: Sat, 1 Aug 2009 10:13:32 +0000 Subject: Update MSVC projects files --- intern/smoke/make/msvc_9_0/smoke.vcproj | 511 ++++++++++++++++++++++++++++++++ 1 file changed, 511 insertions(+) create mode 100644 intern/smoke/make/msvc_9_0/smoke.vcproj (limited to 'intern') diff --git a/intern/smoke/make/msvc_9_0/smoke.vcproj b/intern/smoke/make/msvc_9_0/smoke.vcproj new file mode 100644 index 00000000000..aa3779031f0 --- /dev/null +++ b/intern/smoke/make/msvc_9_0/smoke.vcproj @@ -0,0 +1,511 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- cgit v1.2.3 From f45dcf022db02272d495ddfb07ffffe50e3f7f70 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sun, 2 Aug 2009 03:41:42 +0000 Subject: - X11 tablet was using uninitialized variables. - Added BLENDER_FORCE_SWAPBUFFERS in help message. --- intern/ghost/intern/GHOST_WindowX11.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'intern') diff --git a/intern/ghost/intern/GHOST_WindowX11.cpp b/intern/ghost/intern/GHOST_WindowX11.cpp index 73d61a30977..5a1f3bf1e21 100644 --- a/intern/ghost/intern/GHOST_WindowX11.cpp +++ b/intern/ghost/intern/GHOST_WindowX11.cpp @@ -177,6 +177,8 @@ GHOST_WindowX11( printf("%s:%d: X11 glxChooseVisual() failed for OpenGL, verify working openGL system!\n", __FILE__, __LINE__); return; } + + memset(&m_xtablet, 0, sizeof(m_xtablet)); // Create a bunch of attributes needed to create an X window. -- cgit v1.2.3