From 0b6b37f6a2ee1764e8912fe9f57dd4ed2baadecd Mon Sep 17 00:00:00 2001 From: Christian Ehrhardt Date: Mon, 15 Apr 2019 14:36:48 +0200 Subject: New upstream version 18.11.1 Change-Id: I2394f61ba94cc575bf2c55186f14e5d6fba9eec7 Signed-off-by: Christian Ehrhardt --- examples/ipsec-secgw/sa.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'examples/ipsec-secgw/sa.c') diff --git a/examples/ipsec-secgw/sa.c b/examples/ipsec-secgw/sa.c index d2d3550a..640f1d79 100644 --- a/examples/ipsec-secgw/sa.c +++ b/examples/ipsec-secgw/sa.c @@ -947,10 +947,15 @@ int inbound_sa_check(struct sa_ctx *sa_ctx, struct rte_mbuf *m, uint32_t sa_idx) { struct ipsec_mbuf_metadata *priv; + struct ipsec_sa *sa; priv = get_priv(m); + sa = priv->sa; + if (sa != NULL) + return (sa_ctx->sa[sa_idx].spi == sa->spi); - return (sa_ctx->sa[sa_idx].spi == priv->sa->spi); + RTE_LOG(ERR, IPSEC, "SA not saved in private data\n"); + return 0; } static inline void -- cgit 1.2.3-korg