]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
a_strnid: put includes together
authorNorbert Pocs <norbertp@openssl.org>
Tue, 5 May 2026 10:36:23 +0000 (12:36 +0200)
committerNorbert Pocs <norbertp@openssl.org>
Mon, 18 May 2026 07:03:29 +0000 (09:03 +0200)
clang-tidy calculates where to place the headers to be added. The
maximum is the latest include present in the file.  Therefore the
algorithm sometimes addes the includes wrongly in the middle of the
file.

Signed-off-by: Norbert Pocs <norbertp@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Nikola Pajkovsky <nikolap@openssl.org>
MergeDate: Mon May 18 07:03:47 2026
(Merged from https://github.com/openssl/openssl/pull/31153)

crypto/asn1/a_strnid.c

index 889587133c02aa9f0593a811c53982955871bffb..54117d50eef1fe1c153fb5caa3f473dc16b09de8 100644 (file)
@@ -11,6 +11,7 @@
 #include "internal/cryptlib.h"
 #include <openssl/asn1.h>
 #include <openssl/objects.h>
+#include "tbl_standard.h"
 
 static STACK_OF(ASN1_STRING_TABLE) *stable = NULL;
 static void st_free(ASN1_STRING_TABLE *tbl);
@@ -107,8 +108,6 @@ ASN1_STRING *ASN1_STRING_set_by_NID(ASN1_STRING **out,
  * Now the tables and helper functions for the string table:
  */
 
-#include "tbl_standard.h"
-
 static int sk_table_cmp(const ASN1_STRING_TABLE *const *a,
     const ASN1_STRING_TABLE *const *b)
 {