Forgot to close clipboard when lock fails.
[blender-staging.git] / intern / ghost / intern / GHOST_SystemWin32.cpp
index 92066d5f79466ca48f74892ba4a04a8eef4ff879..143f7e97f2d275897f6a3fc29c602b50b835f2b9 100644 (file)
@@ -1186,6 +1186,7 @@ GHOST_TUns8* GHOST_SystemWin32::getClipboard(bool selection) const
                }
                buffer = (char*)GlobalLock( hData );
                if (!buffer) {
+                       CloseClipboard();
                        return NULL;
                }