use the correct method to get the random length

This commit is contained in:
Hubert Chathi 2018-06-26 22:18:25 -04:00
parent 128d45cc83
commit 552da6eafe

View file

@ -120,7 +120,7 @@ PkDecryption.prototype['free'] = function() {
PkDecryption.prototype['generate_key'] = restore_stack(function () {
var random_length = pk_decryption_method(
Module['_olm_pk_key_length'] // FIXME: wrong method
Module['_olm_pk_generate_key_random_length']
)();
var random_buffer = random_stack(random_length);
var pubkey_length = pk_encryption_method(