summaryrefslogtreecommitdiff
path: root/tools/tools/crypto/cryptokeytest.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/tools/crypto/cryptokeytest.c')
-rw-r--r--tools/tools/crypto/cryptokeytest.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/tools/tools/crypto/cryptokeytest.c b/tools/tools/crypto/cryptokeytest.c
index 9db9eb5fd026..5f0ad74b8eba 100644
--- a/tools/tools/crypto/cryptokeytest.c
+++ b/tools/tools/crypto/cryptokeytest.c
@@ -113,10 +113,7 @@ UB_mod_exp(BIGNUM *res, const BIGNUM *a, const BIGNUM *b, const BIGNUM *c)
{
struct crypt_kop kop;
void *ale, *ble, *cle;
- static int crypto_fd = -1;
-
- if (crypto_fd == -1 && ioctl(devcrypto(), CRIOGET, &crypto_fd) == -1)
- err(1, "CRIOGET");
+ int crypto_fd = devcrypto();
if ((ale = bignum_to_le(a)) == NULL)
err(1, "bignum_to_le, a");