From 0a434b502ca329afd6a7afd0dc474238e146ccd5 Mon Sep 17 00:00:00 2001 From: MikalaiR Date: Fri, 19 Feb 2016 11:10:10 +0000 Subject: code cleanup git-svn-id: http://svn.miranda-ng.org/main/trunk@16306 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/Kuzne4ikCrypt/src/encrypt.cpp | 3 +-- plugins/Kuzne4ikCrypt/src/main.cpp | 21 +++++++++++--------- plugins/Kuzne4ikCrypt/src/stdafx.h | 37 ++--------------------------------- 3 files changed, 15 insertions(+), 46 deletions(-) (limited to 'plugins/Kuzne4ikCrypt') diff --git a/plugins/Kuzne4ikCrypt/src/encrypt.cpp b/plugins/Kuzne4ikCrypt/src/encrypt.cpp index 62b3b3a24c..2d97103691 100644 --- a/plugins/Kuzne4ikCrypt/src/encrypt.cpp +++ b/plugins/Kuzne4ikCrypt/src/encrypt.cpp @@ -98,7 +98,6 @@ bool CCrypt::setKey(const BYTE *pKey, size_t cbKeyLen) if (tmp.m_crc32 != crc32(0xAbbaDead, (LPCBYTE)m_password.GetString(), m_password.GetLength())) return false; - m_valid = true; memcpy(m_key, &tmp.m_key, KEY_LENGTH); init_ecb_14(m_key, m_ctx); @@ -164,7 +163,7 @@ BYTE* CCrypt::encodeBuffer(const void *src, size_t cbLen, size_t *cbResultLen) BYTE *result = (BYTE*)mir_alloc(cbLen); - if (encrypt_ecb(m_ctx, tmpBuf, LPBYTE(result), cbLen)) { + if (encrypt_ecb(m_ctx, tmpBuf, result, cbLen)) { mir_free(result); return NULL; } diff --git a/plugins/Kuzne4ikCrypt/src/main.cpp b/plugins/Kuzne4ikCrypt/src/main.cpp index 9a5e79a77e..b906df6083 100644 --- a/plugins/Kuzne4ikCrypt/src/main.cpp +++ b/plugins/Kuzne4ikCrypt/src/main.cpp @@ -1,21 +1,24 @@ /* -Standard encryption plugin for Miranda NG -Copyright (C) 2012-16 George Hazan +Miranda NG: the free IM client for Microsoft* Windows* -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. +Copyright (C) 2012-16 Miranda NG project, +all portions of this codebase are copyrighted to the people +listed in contributors.txt. + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include "stdafx.h" diff --git a/plugins/Kuzne4ikCrypt/src/stdafx.h b/plugins/Kuzne4ikCrypt/src/stdafx.h index b63c28ba72..baa9cff9c1 100644 --- a/plugins/Kuzne4ikCrypt/src/stdafx.h +++ b/plugins/Kuzne4ikCrypt/src/stdafx.h @@ -2,8 +2,7 @@ Miranda NG: the free IM client for Microsoft* Windows* -Copyright (ñ) 2012-16 Miranda NG project (http://miranda-ng.org), -Copyright (c) 2000-12 Miranda IM project, +Copyright (C) 2012-16 Miranda NG project, all portions of this codebase are copyrighted to the people listed in contributors.txt. @@ -23,50 +22,18 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include -#include -#include -#include -#include +#include -#include -#include -#include -#include -#include -#include -#include -#include -#include #include -#include - -#include #include -#include #include -#include -#include #include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include #include #include #include "version.h" #include "GOST/block_chipher.h" -//#include "resource.h" #include "stdcrypt.h" -- cgit v1.2.3