diff options
author | Ulf Möller <ulf@openssl.org> | 1999-04-19 21:31:43 +0000 |
---|---|---|
committer | Ulf Möller <ulf@openssl.org> | 1999-04-19 21:31:43 +0000 |
commit | 6b691a5c85ddc4e407e32781841fee5c029506cd (patch) | |
tree | 436f1127406e1cacfe83dfcbfff824d89c47d834 /crypto/cast | |
parent | 3edd7ed15de229230f74c79c3d71e7c9c674cf4f (diff) |
Change functions to ANSI C.
Diffstat (limited to 'crypto/cast')
-rw-r--r-- | crypto/cast/c_cfb64.c | 10 | ||||
-rw-r--r-- | crypto/cast/c_ecb.c | 7 | ||||
-rw-r--r-- | crypto/cast/c_enc.c | 17 | ||||
-rw-r--r-- | crypto/cast/c_ofb64.c | 9 | ||||
-rw-r--r-- | crypto/cast/c_skey.c | 5 | ||||
-rw-r--r-- | crypto/cast/cast_spd.c | 10 | ||||
-rw-r--r-- | crypto/cast/castopts.c | 10 | ||||
-rw-r--r-- | crypto/cast/casttest.c | 4 |
8 files changed, 18 insertions, 54 deletions
diff --git a/crypto/cast/c_cfb64.c b/crypto/cast/c_cfb64.c index c46c375f75..a9d32517c4 100644 --- a/crypto/cast/c_cfb64.c +++ b/crypto/cast/c_cfb64.c @@ -64,14 +64,8 @@ * 64bit block we have used is contained in *num; */ -void CAST_cfb64_encrypt(in, out, length, schedule, ivec, num, encrypt) -unsigned char *in; -unsigned char *out; -long length; -CAST_KEY *schedule; -unsigned char *ivec; -int *num; -int encrypt; +void CAST_cfb64_encrypt(unsigned char *in, unsigned char *out, long length, + CAST_KEY *schedule, unsigned char *ivec, int *num, int encrypt) { register CAST_LONG v0,v1,t; register int n= *num; diff --git a/crypto/cast/c_ecb.c b/crypto/cast/c_ecb.c index e6a3d4332e..a407a6d119 100644 --- a/crypto/cast/c_ecb.c +++ b/crypto/cast/c_ecb.c @@ -62,11 +62,8 @@ char *CAST_version="CAST" OPENSSL_VERSION_PTEXT; -void CAST_ecb_encrypt(in, out, ks, encrypt) -unsigned char *in; -unsigned char *out; -CAST_KEY *ks; -int encrypt; +void CAST_ecb_encrypt(unsigned char *in, unsigned char *out, CAST_KEY *ks, + int encrypt) { CAST_LONG l,d[2]; diff --git a/crypto/cast/c_enc.c b/crypto/cast/c_enc.c index 7d861de965..2a26e277c8 100644 --- a/crypto/cast/c_enc.c +++ b/crypto/cast/c_enc.c @@ -59,9 +59,7 @@ #include "cast.h" #include "cast_lcl.h" -void CAST_encrypt(data,key) -CAST_LONG *data; -CAST_KEY *key; +void CAST_encrypt(CAST_LONG *data, CAST_KEY *key) { register CAST_LONG l,r,*k,t; @@ -93,9 +91,7 @@ CAST_KEY *key; data[0]=r&0xffffffffL; } -void CAST_decrypt(data,key) -CAST_LONG *data; -CAST_KEY *key; +void CAST_decrypt(CAST_LONG *data, CAST_KEY *key) { register CAST_LONG l,r,*k,t; @@ -127,13 +123,8 @@ CAST_KEY *key; data[0]=r&0xffffffffL; } -void CAST_cbc_encrypt(in, out, length, ks, iv, encrypt) -unsigned char *in; -unsigned char *out; -long length; -CAST_KEY *ks; -unsigned char *iv; -int encrypt; +void CAST_cbc_encrypt(unsigned char *in, unsigned char *out, long length, + CAST_KEY *ks, unsigned char *iv, int encrypt) { register CAST_LONG tin0,tin1; register CAST_LONG tout0,tout1,xor0,xor1; diff --git a/crypto/cast/c_ofb64.c b/crypto/cast/c_ofb64.c index 2aad2d6d96..1ccaec7976 100644 --- a/crypto/cast/c_ofb64.c +++ b/crypto/cast/c_ofb64.c @@ -63,13 +63,8 @@ * used. The extra state information to record how much of the * 64bit block we have used is contained in *num; */ -void CAST_ofb64_encrypt(in, out, length, schedule, ivec, num) -unsigned char *in; -unsigned char *out; -long length; -CAST_KEY *schedule; -unsigned char *ivec; -int *num; +void CAST_ofb64_encrypt(unsigned char *in, unsigned char *out, long length, + CAST_KEY *schedule, unsigned char *ivec, int *num) { register CAST_LONG v0,v1,t; register int n= *num; diff --git a/crypto/cast/c_skey.c b/crypto/cast/c_skey.c index 5262a2ebd2..7611f7a1e4 100644 --- a/crypto/cast/c_skey.c +++ b/crypto/cast/c_skey.c @@ -72,10 +72,7 @@ #define S6 CAST_S_table6 #define S7 CAST_S_table7 -void CAST_set_key(key,len,data) -CAST_KEY *key; -int len; -unsigned char *data; +void CAST_set_key(CAST_KEY *key, int len, unsigned char *data) { CAST_LONG x[16]; CAST_LONG z[16]; diff --git a/crypto/cast/cast_spd.c b/crypto/cast/cast_spd.c index 885b1df23d..5e3716af84 100644 --- a/crypto/cast/cast_spd.c +++ b/crypto/cast/cast_spd.c @@ -135,8 +135,7 @@ SIGRETTYPE sig_done(int sig); SIGRETTYPE sig_done(); #endif -SIGRETTYPE sig_done(sig) -int sig; +SIGRETTYPE sig_done(int sig) { signal(SIGALRM,sig_done); run=0; @@ -149,8 +148,7 @@ int sig; #define START 0 #define STOP 1 -double Time_F(s) -int s; +double Time_F(int s) { double ret; #ifdef TIMES @@ -186,9 +184,7 @@ int s; #endif } -int main(argc,argv) -int argc; -char **argv; +int main(int argc, char **argv) { long count; static unsigned char buf[BUFSIZE]; diff --git a/crypto/cast/castopts.c b/crypto/cast/castopts.c index 8635b46a02..2c9e550cbd 100644 --- a/crypto/cast/castopts.c +++ b/crypto/cast/castopts.c @@ -172,8 +172,7 @@ SIGRETTYPE sig_done(int sig); SIGRETTYPE sig_done(); #endif -SIGRETTYPE sig_done(sig) -int sig; +SIGRETTYPE sig_done(int sig) { signal(SIGALRM,sig_done); run=0; @@ -186,8 +185,7 @@ int sig; #define START 0 #define STOP 1 -double Time_F(s) -int s; +double Time_F(int s) { double ret; #ifdef TIMES @@ -248,9 +246,7 @@ int s; fprintf(stderr,"%s bytes per sec = %12.2f (%5.1fuS)\n",name, \ tm[index]*8,1.0e6/tm[index]); -int main(argc,argv) -int argc; -char **argv; +int main(int argc, char **argv) { long count; static unsigned char buf[BUFSIZE]; diff --git a/crypto/cast/casttest.c b/crypto/cast/casttest.c index d55400f5be..7039266803 100644 --- a/crypto/cast/casttest.c +++ b/crypto/cast/casttest.c @@ -120,9 +120,7 @@ static unsigned char cfb_cipher64[CFB_TEST_SIZE]={ }; #endif -int main(argc,argv) -int argc; -char *argv[]; +int main(int argc, char *argv[]) { #ifdef FULL_TEST long l; |