From 0f7fe469804e8377c568e398ffc6c6d240f9171d Mon Sep 17 00:00:00 2001 From: Akash Mozumdar Date: Thu, 10 Jan 2019 21:55:11 -0500 Subject: [PATCH] dont copy infinitely when clipboard is selected with clipboard copy extension --- extensions/copyclipboard.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/copyclipboard.cpp b/extensions/copyclipboard.cpp index 77d817a..cc72367 100644 --- a/extensions/copyclipboard.cpp +++ b/extensions/copyclipboard.cpp @@ -2,7 +2,7 @@ bool ProcessSentence(std::wstring& sentence, SentenceInfo sentenceInfo) { - if (sentenceInfo["current select"] && sentenceInfo["hook address"] != -1) + if (sentenceInfo["current select"] && sentenceInfo["process id"] != 0) { if (!OpenClipboard(FindWindowW(NULL, L"Textractor"))) return false; HGLOBAL hMem = GlobalAlloc(GMEM_MOVEABLE, (sentence.size() + 2) * sizeof(wchar_t));