From 58b6deafb08a2213936df9ab71ae69f28f62e41d Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Fri, 16 Nov 2012 06:58:48 +0000 Subject: tabs and spaces cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@2325 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/modules/crypt/encrypt.cpp | 26 +++++++++----------------- 1 file changed, 9 insertions(+), 17 deletions(-) (limited to 'src/modules/crypt') diff --git a/src/modules/crypt/encrypt.cpp b/src/modules/crypt/encrypt.cpp index 8880341c58..dbb2ee3374 100644 --- a/src/modules/crypt/encrypt.cpp +++ b/src/modules/crypt/encrypt.cpp @@ -25,41 +25,33 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. //VERY VERY VERY BASIC ENCRYPTION FUNCTION -void Encrypt(char*msg,BOOL up) +void Encrypt(char*msg, BOOL up) { - int i; int jump; if (up) - { jump = 5; - } else - { jump = -5; - } - - for (i = 0;msg[i];i++) - { - msg[i] = msg[i]+jump; - } + for (int i = 0; msg[i]; i++) + msg[i] = msg[i] + jump; } -static INT_PTR EncodeString(WPARAM wParam,LPARAM lParam) +static INT_PTR EncodeString(WPARAM wParam, LPARAM lParam) { - Encrypt((char*)lParam,TRUE); + Encrypt((char*)lParam, TRUE); return 0; } -static INT_PTR DecodeString(WPARAM wParam,LPARAM lParam) +static INT_PTR DecodeString(WPARAM wParam, LPARAM lParam) { - Encrypt((char*)lParam,FALSE); + Encrypt((char*)lParam, FALSE); return 0; } int InitCrypt(void) { - CreateServiceFunction(MS_DB_CRYPT_ENCODESTRING,EncodeString); - CreateServiceFunction(MS_DB_CRYPT_DECODESTRING,DecodeString); + CreateServiceFunction(MS_DB_CRYPT_ENCODESTRING, EncodeString); + CreateServiceFunction(MS_DB_CRYPT_DECODESTRING, DecodeString); return 0; } -- cgit v1.2.3