mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-29 11:41:15 +03:00
- Require different input and output buffer in cipher_update()
- Fixed style typos
This commit is contained in:
@ -197,8 +197,11 @@ int cipher_update( cipher_context_t *ctx, const unsigned char *input, int ilen,
|
|||||||
{
|
{
|
||||||
int copy_len = 0;
|
int copy_len = 0;
|
||||||
|
|
||||||
if( NULL == ctx || NULL == ctx->cipher_info || NULL == olen )
|
if( NULL == ctx || NULL == ctx->cipher_info || NULL == olen ||
|
||||||
|
input == output )
|
||||||
|
{
|
||||||
return 1;
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
*olen = 0;
|
*olen = 0;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user