Revision: 41189
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=41189
Author:   alexk
Date:     2011-10-22 04:36:58 +0000 (Sat, 22 Oct 2011)
Log Message:
-----------
Fix for alt-tab in Windows.
utf8_buf can be not null terminated, plus not init as in this case. (I need to 
investigate more)

Modified Paths:
--------------
    trunk/blender/source/blender/windowmanager/intern/wm_event_system.c

Modified: trunk/blender/source/blender/windowmanager/intern/wm_event_system.c
===================================================================
--- trunk/blender/source/blender/windowmanager/intern/wm_event_system.c 
2011-10-22 03:39:13 UTC (rev 41188)
+++ trunk/blender/source/blender/windowmanager/intern/wm_event_system.c 
2011-10-22 04:36:58 UTC (rev 41189)
@@ -2611,7 +2611,7 @@
                        GHOST_TEventKeyData *kd= customdata;
                        event.type= convert_key(kd->key);
                        event.ascii= kd->ascii;
-                       strcpy(event.utf8_buf, kd->utf8_buf);
+                       memcpy(event.utf8_buf, 
kd->utf8_buf,sizeof(event.utf8_buf));/* might be not null terminated*/
                        event.val= 
(type==GHOST_kEventKeyDown)?KM_PRESS:KM_RELEASE;
                        
                        /* exclude arrow keys, esc, etc from text input */

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to