summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mir_core/src/Windows/winutil.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mir_core/src/Windows/winutil.cpp b/src/mir_core/src/Windows/winutil.cpp
index 1d18041529..d512e5ecf2 100644
--- a/src/mir_core/src/Windows/winutil.cpp
+++ b/src/mir_core/src/Windows/winutil.cpp
@@ -147,7 +147,7 @@ MIR_CORE_DLL(void) Utils_ClipboardCopy(const char *pszText)
EmptyClipboard();
- HGLOBAL hData = ::GlobalAlloc(GMEM_MOVEABLE | GMEM_SHARE, cbLen);
+ HGLOBAL hData = ::GlobalAlloc(GMEM_MOVEABLE | GMEM_SHARE, cbLen+1);
if (hData) {
mir_strcpy((char *)GlobalLock(hData), pszText);
GlobalUnlock(hData);