From: Caolán McNamara Date: Sat, 26 Jul 2025 20:00:50 +0000 (+0100) Subject: ITS#10375 libldap/tls2: const up oids X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=f584da2fe7fc0c0f3cbbe382c8ba33585432f909;p=thirdparty%2Fopenldap.git ITS#10375 libldap/tls2: const up oids to move it out of the .data section --- diff --git a/libraries/libldap/tls2.c b/libraries/libldap/tls2.c index 1bda3fb2aa..1fb878aab8 100644 --- a/libraries/libldap/tls2.c +++ b/libraries/libldap/tls2.c @@ -51,7 +51,7 @@ typedef struct oid_name { struct berval name; } oid_name; -static oid_name oids[] = { +static const oid_name oids[] = { { BER_BVC("2.5.4.3"), BER_BVC("cn") }, { BER_BVC("2.5.4.4"), BER_BVC("sn") }, { BER_BVC("2.5.4.6"), BER_BVC("c") }, @@ -1394,7 +1394,7 @@ ldap_start_tls_s ( LDAP *ld, #define LBER_TAG_UNIVERSAL ((ber_tag_t) 0x1cUL) #define LBER_TAG_BMP ((ber_tag_t) 0x1eUL) -static oid_name * +static const oid_name * find_oid( struct berval *oid ) { int i; @@ -1519,7 +1519,7 @@ ldap_X509dn2bv( void *x509_name, struct berval *bv, LDAPDN_rewrite_func *func, int csize; ber_tag_t tag; ber_len_t len; - oid_name *oidname; + const oid_name *oidname; struct berval Oid, Val, oid2, *in = x509_name;