X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=crypto%2Fevp%2Fbio_ok.c;h=101275d6487085c8e48f902ea604b3a8189b74de;hb=10cea23bd46cb43fab1de5c59828ae67f80975c3;hp=fbd6d532c622d678c21d11aae4a792c654193dee;hpb=95dc05bc6d0dfe0f3f3681f5e27afbc3f7a35eea;p=oweals%2Fopenssl.git diff --git a/crypto/evp/bio_ok.c b/crypto/evp/bio_ok.c index fbd6d532c6..101275d648 100644 --- a/crypto/evp/bio_ok.c +++ b/crypto/evp/bio_ok.c @@ -120,12 +120,11 @@ #include #include #include "cryptlib.h" -#include "buffer.h" -#include "bio.h" -#include "evp.h" -#include "rand.h" +#include +#include +#include +#include -#ifndef NOPROTO static int ok_write(BIO *h,char *buf,int num); static int ok_read(BIO *h,char *buf,int size); static long ok_ctrl(BIO *h,int cmd,long arg1,char *arg2); @@ -135,18 +134,6 @@ static void sig_out(BIO* b); static void sig_in(BIO* b); static void block_out(BIO* b); static void block_in(BIO* b); -#else -static int ok_write(); -static int ok_read(); -static long ok_ctrl(); -static int ok_new(); -static int ok_free(); -static void sig_out(); -static void sig_in(); -static void block_out(); -static void block_in(); -#endif - #define OK_BLOCK_SIZE (1024*4) #define OK_BLOCK_BLOCK 4 #define IOBS (OK_BLOCK_SIZE+ OK_BLOCK_BLOCK+ 3*EVP_MAX_MD_SIZE) @@ -441,10 +428,11 @@ static long ok_ctrl(BIO *b, int cmd, long num, char *ptr) return(ret); } -static void longswap(char* ptr, int len) +static void longswap(void *_ptr, int len) { #ifndef L_ENDIAN int i; + char *ptr=_ptr; for(i= 0;i < len;i+= 4){ *((unsigned long *)&(ptr[i]))= swapem(*((unsigned long *)&(ptr[i]))); @@ -535,7 +523,7 @@ static void block_in(BIO* b) { BIO_OK_CTX *ctx; EVP_MD_CTX *md; - long tl= 0; + long tl= 0; unsigned char tmp[EVP_MAX_MD_SIZE]; ctx=(BIO_OK_CTX *)b->ptr;