wincng: Made data parameter to hash update function constant

Initially reported by Bob Kast as "formal parameter must be const
since it is used in contexts where the actual parameter may be const".
Thanks a lot.
This commit is contained in:
Marc Hoersken 2014-05-17 23:35:11 +02:00
parent 6e710d7fb6
commit a58b0dacb4

View File

@ -329,11 +329,11 @@ _libssh2_wincng_hash_init(_libssh2_wincng_hash_ctx *ctx,
int
_libssh2_wincng_hash_update(_libssh2_wincng_hash_ctx *ctx,
unsigned char *data, unsigned long datalen)
const unsigned char *data, unsigned long datalen)
{
int ret;
ret = BCryptHashData(ctx->hHash, data, datalen, 0);
ret = BCryptHashData(ctx->hHash, (unsigned char *)data, datalen, 0);
return BCRYPT_SUCCESS(ret) ? 0 : -1;
}