Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/crypto/external/bsd/openssl/dist/crypto fix warnings for the...
details: https://anonhg.NetBSD.org/src/rev/454506d38100
branches: trunk
changeset: 765993:454506d38100
user: christos <christos%NetBSD.org@localhost>
date: Sun Jun 12 16:15:42 2011 +0000
description:
fix warnings for the patented algos
diffstat:
crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c | 6 +++---
crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c | 6 +++---
2 files changed, 6 insertions(+), 6 deletions(-)
diffs (60 lines):
diff -r de1303be2da3 -r 454506d38100 crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c
--- a/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c Sun Jun 12 14:47:20 2011 +0000
+++ b/crypto/external/bsd/openssl/dist/crypto/idea/ideatest.c Sun Jun 12 16:15:42 2011 +0000
@@ -79,7 +79,7 @@
unsigned char c[8]={0x11,0xFB,0xED,0x2B,0x01,0x98,0x6D,0xE5};
unsigned char out[80];
-char *text="Hello to all people out there";
+const char *text="Hello to all people out there";
static unsigned char cfb_key[16]={
0xe1,0xf0,0xc3,0xd2,0xa5,0xb4,0x87,0x96,
@@ -148,7 +148,7 @@
if (err == 0) printf("ecb idea ok\n");
memcpy(iv,k,8);
- idea_cbc_encrypt((unsigned char *)text,out,strlen(text)+1,&key,iv,1);
+ idea_cbc_encrypt((const unsigned char *)text,out,strlen(text)+1,&key,iv,1);
memcpy(iv,k,8);
idea_cbc_encrypt(out,out,8,&dkey,iv,0);
idea_cbc_encrypt(&(out[8]),&(out[8]),strlen(text)+1-8,&dkey,iv,0);
@@ -220,7 +220,7 @@
static int bnum=0;
char *ret;
int i;
- static char *f="0123456789ABCDEF";
+ static const char *f="0123456789ABCDEF";
ret= &(bufs[bnum++][0]);
bnum%=10;
diff -r de1303be2da3 -r 454506d38100 crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c
--- a/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c Sun Jun 12 14:47:20 2011 +0000
+++ b/crypto/external/bsd/openssl/dist/crypto/mdc2/mdc2test.c Sun Jun 12 16:15:42 2011 +0000
@@ -96,7 +96,7 @@
unsigned char md[MDC2_DIGEST_LENGTH];
int i;
EVP_MD_CTX c;
- static char *text="Now is the time for all ";
+ static const char *text="Now is the time for all ";
#ifdef CHARSET_EBCDIC
ebcdic2ascii(text,text,strlen(text));
@@ -104,7 +104,7 @@
EVP_MD_CTX_init(&c);
EVP_DigestInit_ex(&c,EVP_mdc2(), NULL);
- EVP_DigestUpdate(&c,(unsigned char *)text,strlen(text));
+ EVP_DigestUpdate(&c,(const unsigned char *)text,strlen(text));
EVP_DigestFinal_ex(&c,&(md[0]),NULL);
if (memcmp(md,pad1,MDC2_DIGEST_LENGTH) != 0)
@@ -123,7 +123,7 @@
EVP_DigestInit_ex(&c,EVP_mdc2(), NULL);
/* FIXME: use a ctl function? */
((MDC2_CTX *)c.md_data)->pad_type=2;
- EVP_DigestUpdate(&c,(unsigned char *)text,strlen(text));
+ EVP_DigestUpdate(&c,(const unsigned char *)text,strlen(text));
EVP_DigestFinal_ex(&c,&(md[0]),NULL);
if (memcmp(md,pad2,MDC2_DIGEST_LENGTH) != 0)
Home |
Main Index |
Thread Index |
Old Index