diff --git a/res/values-he b/res/values-he new file mode 120000 index 000000000..6fe8b4958 --- /dev/null +++ b/res/values-he @@ -0,0 +1 @@ +values-iw \ No newline at end of file diff --git a/res/values-id b/res/values-id new file mode 120000 index 000000000..9ea8dda4b --- /dev/null +++ b/res/values-id @@ -0,0 +1 @@ +values-in \ No newline at end of file diff --git a/src/net/java/otr4j/crypto/SM.java b/src/net/java/otr4j/crypto/SM.java index c91447185..af20ada2b 100644 --- a/src/net/java/otr4j/crypto/SM.java +++ b/src/net/java/otr4j/crypto/SM.java @@ -183,7 +183,7 @@ public static BigInteger[] unserialize(byte[] bytes) throws SMException { * element */ public static boolean checkGroupElem(BigInteger g) { - return !(g.compareTo(BigInteger.valueOf(2)) > 0 && g.compareTo(SM.MODULUS_MINUS_2) < 0); + return g.compareTo(BigInteger.valueOf(2)) < 0 || g.compareTo(SM.MODULUS_MINUS_2) > 0; } /** @@ -191,7 +191,7 @@ public static boolean checkGroupElem(BigInteger g) { * exponent */ public static boolean checkExpon(BigInteger x) { - return !(x.compareTo(BigInteger.ONE) > 0 && x.compareTo(SM.ORDER_S) <= 0); + return x.compareTo(BigInteger.ONE) < 0 || x.compareTo(SM.ORDER_S) >= 0; } /**