Use separate lrz_encrypt and lrz_decrypt wrappers to lrz_crypt.

This commit is contained in:
Con Kolivas 2011-03-19 14:04:22 +11:00
parent 0b1db75a44
commit ff5a5ed054
5 changed files with 20 additions and 7 deletions

View file

@ -1195,7 +1195,7 @@ retry:
get_rand(cti->salt, 8);
memcpy(cti->salt + 8, &cti->c_len, 8);
memcpy(cti->salt + 16, &cti->s_len, 8);
lrz_crypt(control, cti->s_buf, padded_len, cti->salt, 1);
lrz_encrypt(control, cti->s_buf, padded_len, cti->salt);
}
/* If compression fails for whatever reason multithreaded, then wait
@ -1465,7 +1465,7 @@ fill_another:
return -1;
if (ENCRYPT)
lrz_crypt(control, s_buf, padded_len, salt, 0);
lrz_decrypt(control, s_buf, padded_len, salt);
ucthread[s->uthread_no].s_buf = s_buf;
ucthread[s->uthread_no].c_len = c_len;