forked from enlightenment/efl
fix typo: cypher -> cipher
also reduce scope of ciphered and ciphered_len. SVN revision: 37609
This commit is contained in:
parent
817e679d29
commit
ca1c7d5bfc
|
@ -321,9 +321,9 @@ eet_identity_certificate_print(const unsigned char *certificate, int der_length,
|
|||
}
|
||||
|
||||
Eet_Error
|
||||
eet_cypher(void *data, unsigned int size, const char *key, unsigned int length)
|
||||
eet_cipher(const void *data, unsigned int size, const char *key, unsigned int length, void **result, unsigned int *result_length)
|
||||
{
|
||||
#ifdef HAVE_CYPHER
|
||||
#ifdef HAVE_CIPHER
|
||||
(void) data;
|
||||
(void) size;
|
||||
(void) key;
|
||||
|
@ -339,9 +339,9 @@ eet_cypher(void *data, unsigned int size, const char *key, unsigned int length)
|
|||
}
|
||||
|
||||
Eet_Error
|
||||
eet_decypher(void *data, unsigned int size, const char *key, unsigned int length)
|
||||
eet_decipher(const void *data, unsigned int size, const char *key, unsigned int length, void **result, unsigned int *result_length)
|
||||
{
|
||||
#ifdef HAVE_CYPHER
|
||||
#ifdef HAVE_CIPHER
|
||||
(void) data;
|
||||
(void) size;
|
||||
(void) key;
|
||||
|
|
|
@ -3130,22 +3130,23 @@ eet_data_text_undump_cipher(const char *text,
|
|||
int *size_ret)
|
||||
{
|
||||
void *ret = NULL;
|
||||
void *cyphered = NULL;
|
||||
unsigned int cyphered_len;
|
||||
|
||||
ret = _eet_data_dump_parse(NULL, size_ret, text, textlen);
|
||||
if (ret && key)
|
||||
{
|
||||
if (eet_cipher(ret, *size_ret, key, strlen(key), &cyphered, &cyphered_len))
|
||||
void *ciphered = NULL;
|
||||
unsigned int ciphered_len;
|
||||
|
||||
if (eet_cipher(ret, *size_ret, key, strlen(key), &ciphered, &ciphered_len))
|
||||
{
|
||||
if (cyphered) free(cyphered);
|
||||
if (ciphered) free(ciphered);
|
||||
size_ret = 0;
|
||||
free(ret);
|
||||
return NULL;
|
||||
}
|
||||
free(ret);
|
||||
*size_ret = cyphered_len;
|
||||
ret = cyphered;
|
||||
*size_ret = ciphered_len;
|
||||
ret = ciphered;
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue