From 05938ae432571acc8568920b95fd28fc5adfc33e Mon Sep 17 00:00:00 2001 From: MikalaiR Date: Thu, 17 Dec 2015 11:27:34 +0000 Subject: ICQCorp: encoding fix, crash fix(?) git-svn-id: http://svn.miranda-ng.org/main/trunk@15880 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/ICQCorp/src/protocol.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'protocols/ICQCorp/src/protocol.cpp') diff --git a/protocols/ICQCorp/src/protocol.cpp b/protocols/ICQCorp/src/protocol.cpp index 2ff22d3a41..5ec6c93449 100644 --- a/protocols/ICQCorp/src/protocol.cpp +++ b/protocols/ICQCorp/src/protocol.cpp @@ -1615,8 +1615,9 @@ ICQTransfer *ICQ::sendFile(ICQUser *u, char *description, char *filename, unsign transfer->count = i; transfer->totalSize = size; - transfer->path = _strdup(files[0]); - *strrchr(transfer->path, '\\') = 0; + transfer->path = mir_strdup(transfer->files[0]); + char *s = strrchr(transfer->path, '\\'); + if (s != NULL) *s = 0; icqTransfers.push_back(transfer); transfer->ack(ACKRESULT_SENTREQUEST); -- cgit v1.2.3