forked from bartvdbraak/blender
Bugfix: Pasting non-text data (or trying to retrieve non-text data from the clipboard) crashed blender on Windows.
This commit is contained in:
parent
07b8c7e887
commit
20af6c61e8
@ -919,6 +919,8 @@ GHOST_TUns8* GHOST_SystemWin32::getClipboard(int flag) const
|
||||
|
||||
if ( OpenClipboard(NULL) ) {
|
||||
HANDLE hData = GetClipboardData( CF_TEXT );
|
||||
if (hData == NULL)
|
||||
return NULL;
|
||||
buffer = (char*)GlobalLock( hData );
|
||||
|
||||
temp_buff = (char*) malloc(strlen(buffer)+1);
|
||||
|
Loading…
Reference in New Issue
Block a user