Module: wine Branch: master Commit: b3be5bcd1c8942190fad29cdd4462a561f1b669d URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=b3be5bcd1c8942190fad29cd...
Author: Andrew Talbot Andrew.Talbot@talbotville.com Date: Tue Sep 26 22:06:33 2006 +0100
rsaenh: Cast-qual warnings fix.
---
dlls/rsaenh/mpi.c | 2 +- dlls/rsaenh/rsa.c | 4 ++-- dlls/rsaenh/tomcrypt.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/dlls/rsaenh/mpi.c b/dlls/rsaenh/mpi.c index 8ff2619..b20f0dc 100644 --- a/dlls/rsaenh/mpi.c +++ b/dlls/rsaenh/mpi.c @@ -3331,7 +3331,7 @@ error:
/* reads an unsigned char array, assumes the msb is stored first [big endian] */ int -mp_read_unsigned_bin (mp_int * a, unsigned char *b, int c) +mp_read_unsigned_bin (mp_int * a, const unsigned char *b, int c) { int res;
diff --git a/dlls/rsaenh/rsa.c b/dlls/rsaenh/rsa.c index 2013c83..4d6cd03 100644 --- a/dlls/rsaenh/rsa.c +++ b/dlls/rsaenh/rsa.c @@ -196,8 +196,8 @@ int rsa_exptmod(const unsigned char *in, }
/* init and copy into tmp */ - if ((err = mp_init_multi(&tmp, &tmpa, &tmpb, NULL)) != MP_OKAY) { return mpi_to_ltc_error(err); } - if ((err = mp_read_unsigned_bin(&tmp, (unsigned char *)in, (int)inlen)) != MP_OKAY) { goto error; } + if ((err = mp_init_multi(&tmp, &tmpa, &tmpb, NULL)) != MP_OKAY) { return mpi_to_ltc_error(err); } + if ((err = mp_read_unsigned_bin(&tmp, in, (int)inlen)) != MP_OKAY) { goto error; }
/* sanity check on the input */ if (mp_cmp(&key->N, &tmp) == MP_LT) { diff --git a/dlls/rsaenh/tomcrypt.h b/dlls/rsaenh/tomcrypt.h index 8241ae2..efddd90 100644 --- a/dlls/rsaenh/tomcrypt.h +++ b/dlls/rsaenh/tomcrypt.h @@ -545,7 +545,7 @@ int mp_prime_random_ex(mp_int *a, int t, int mp_count_bits(mp_int *a);
int mp_unsigned_bin_size(mp_int *a); -int mp_read_unsigned_bin(mp_int *a, unsigned char *b, int c); +int mp_read_unsigned_bin(mp_int *a, const unsigned char *b, int c); int mp_to_unsigned_bin(mp_int *a, unsigned char *b);
int mp_signed_bin_size(mp_int *a);