Drop superfluous parentheses in X509_set_version()
authortb <tb@openbsd.org>
Tue, 26 Mar 2024 23:21:36 +0000 (23:21 +0000)
committertb <tb@openbsd.org>
Tue, 26 Mar 2024 23:21:36 +0000 (23:21 +0000)
lib/libcrypto/x509/x509_set.c

index 4add8cf..442bc12 100644 (file)
@@ -1,4 +1,4 @@
-/* $OpenBSD: x509_set.c,v 1.28 2024/03/26 22:44:57 tb Exp $ */
+/* $OpenBSD: x509_set.c,v 1.29 2024/03/26 23:21:36 tb Exp $ */
 /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
  * All rights reserved.
  *
@@ -83,19 +83,19 @@ int
 X509_set_version(X509 *x, long version)
 {
        if (x == NULL)
-               return (0);
+               return 0;
        /*
         * RFC 5280, 4.1: versions 1 - 3 are specified as follows.
         * Version  ::=  INTEGER  {  v1(0), v2(1), v3(2) }
         */
        if (version < 0 || version > 2)
-               return (0);
+               return 0;
        if (x->cert_info->version == NULL) {
                if ((x->cert_info->version = ASN1_INTEGER_new()) == NULL)
-                       return (0);
+                       return 0;
        }
        x->cert_info->enc.modified = 1;
-       return (ASN1_INTEGER_set(x->cert_info->version, version));
+       return ASN1_INTEGER_set(x->cert_info->version, version);
 }
 LCRYPTO_ALIAS(X509_set_version);