From 9c66032fdc937f852771949c4b4c94ade67324d8 Mon Sep 17 00:00:00 2001 From: Alexander Lantsev Date: Tue, 6 Jan 2015 09:41:17 +0000 Subject: Tox: - fixed file transfer with size > 2mb - fixed file lock after transfer - accelerated file transfers git-svn-id: http://svn.miranda-ng.org/main/trunk@11778 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/Tox/src/tox_proto.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'protocols/Tox/src/tox_proto.h') diff --git a/protocols/Tox/src/tox_proto.h b/protocols/Tox/src/tox_proto.h index d7937fdfc1..2565ceb70d 100644 --- a/protocols/Tox/src/tox_proto.h +++ b/protocols/Tox/src/tox_proto.h @@ -4,11 +4,15 @@ struct FileTransferParam { PROTOFILETRANSFERSTATUS pfts; + bool isTerminated; + FILE *hFile; int number; FileTransferParam(int fileNumber, const TCHAR* fileName, size_t fileSize) { + isTerminated = false; number = fileNumber; + hFile = NULL; pfts.cbSize = sizeof(PROTOFILETRANSFERSTATUS); pfts.flags = PFTS_TCHAR; @@ -34,6 +38,7 @@ struct FileTransferParam ~FileTransferParam() { + isTerminated = true; if (pfts.tszWorkingDir != NULL) { mir_free(pfts.tszWorkingDir); @@ -112,7 +117,7 @@ private: Tox *tox; mir_cs toxLock; TCHAR *accountName; - HANDLE hNetlib, hPollingThread; + HANDLE hNetlib, hPollingThread, hToxEvent; bool isTerminated, isConnected; std::map transfers; -- cgit v1.2.3