From 8ca8bc810d0555acdb8c62824e6a4904d840d233 Mon Sep 17 00:00:00 2001 From: orignal Date: Tue, 8 Jan 2019 09:23:14 -0500 Subject: [PATCH] take elgamal percomputation from config --- libi2pd/api.cpp | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/libi2pd/api.cpp b/libi2pd/api.cpp index 415118ff..ca72ae49 100644 --- a/libi2pd/api.cpp +++ b/libi2pd/api.cpp @@ -28,14 +28,11 @@ namespace api i2p::fs::DetectDataDir(datadir, false); i2p::fs::Init(); -#if defined(__x86_64__) - i2p::crypto::InitCrypto (false); -#else - i2p::crypto::InitCrypto (true); -#endif - - int netID; i2p::config::GetOption("netid", netID); - i2p::context.SetNetID (netID); + bool precomputation; i2p::config::GetOption("precomputation.elgamal", precomputation); + i2p::crypto::InitCrypto (precomputation); + + int netID; i2p::config::GetOption("netid", netID); + i2p::context.SetNetID (netID); i2p::context.Init (); }