From 800b81d3efb7315f7e2ca3b524f36edcb17a8e7f Mon Sep 17 00:00:00 2001 From: Sokolovskyy Roman Date: Thu, 20 Jul 2017 11:36:51 +0200 Subject: [PATCH] remove unneeded strlen call --- phpseclib/Crypt/Twofish.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpseclib/Crypt/Twofish.php b/phpseclib/Crypt/Twofish.php index 3c1f6dcb..9193e650 100644 --- a/phpseclib/Crypt/Twofish.php +++ b/phpseclib/Crypt/Twofish.php @@ -402,7 +402,7 @@ class Twofish extends BlockCipher case 256: break; default: - throw new \LengthException('Key of size ' . strlen($key) . ' not supported by this algorithm. Only keys of sizes 16, 24 or 32 supported'); + throw new \LengthException('Key of size ' . $length . ' not supported by this algorithm. Only keys of sizes 16, 24 or 32 supported'); } parent::setKeyLength($length);