From 9395df6f6358dcbac4acfa747d8a52a60654ff35 Mon Sep 17 00:00:00 2001 From: tb Date: Mon, 23 May 2022 14:10:18 +0000 Subject: [PATCH] Improve #ifdefs for STACK_OF() helpers. Discussed with claudio --- usr.sbin/rpki-client/mft.c | 4 ++-- usr.sbin/rpki-client/roa.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/usr.sbin/rpki-client/mft.c b/usr.sbin/rpki-client/mft.c index bcf3217abdc..fb26b992274 100644 --- a/usr.sbin/rpki-client/mft.c +++ b/usr.sbin/rpki-client/mft.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mft.c,v 1.67 2022/05/19 07:33:02 tb Exp $ */ +/* $OpenBSD: mft.c,v 1.68 2022/05/23 14:10:18 tb Exp $ */ /* * Copyright (c) 2019 Kristaps Dzonsons * @@ -57,7 +57,7 @@ typedef struct { DECLARE_STACK_OF(FileAndHash); -#if defined(LIBRESSL_VERSION_NUMBER) +#ifndef DEFINE_STACK_OF #define sk_FileAndHash_num(sk) SKM_sk_num(FileAndHash, (sk)) #define sk_FileAndHash_value(sk, i) SKM_sk_value(FileAndHash, (sk), (i)) #endif diff --git a/usr.sbin/rpki-client/roa.c b/usr.sbin/rpki-client/roa.c index d9cb84838cb..cbb5709df8f 100644 --- a/usr.sbin/rpki-client/roa.c +++ b/usr.sbin/rpki-client/roa.c @@ -1,4 +1,4 @@ -/* $OpenBSD: roa.c,v 1.44 2022/05/19 07:33:02 tb Exp $ */ +/* $OpenBSD: roa.c,v 1.45 2022/05/23 14:10:18 tb Exp $ */ /* * Copyright (c) 2019 Kristaps Dzonsons * @@ -59,7 +59,7 @@ typedef struct { DECLARE_STACK_OF(ROAIPAddressFamily); -#if defined(LIBRESSL_VERSION_NUMBER) +#ifndef DEFINE_STACK_OF #define sk_ROAIPAddress_num(st) SKM_sk_num(ROAIPAddress, (st)) #define sk_ROAIPAddress_value(st, i) SKM_sk_value(ROAIPAddress, (st), (i)) -- 2.20.1