summaryrefslogtreecommitdiff
path: root/src/modules/crypt
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2012-11-16 06:58:48 +0000
committerKirill Volinsky <mataes2007@gmail.com>2012-11-16 06:58:48 +0000
commit58b6deafb08a2213936df9ab71ae69f28f62e41d (patch)
tree064f02295139a6419a20ca87c565194817041218 /src/modules/crypt
parenta0e65f57dd9f199f1143e4b91fad938eaf87d8f9 (diff)
tabs and spaces cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@2325 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src/modules/crypt')
-rw-r--r--src/modules/crypt/encrypt.cpp26
1 files changed, 9 insertions, 17 deletions
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;
}