X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=lib%2Fipsec%2Fesp_outb.c;h=5a5429a12b824d0100f96d4b8f44232fbf55ab09;hb=3d171da6e700901a82bfdbf676a82c299ef50f38;hp=6925bb994510448856237bb5cab9a6fc6c2f18f4;hpb=30a1de105a5f40d77b344a891c4a68f79e815c43;p=dpdk.git diff --git a/lib/ipsec/esp_outb.c b/lib/ipsec/esp_outb.c index 6925bb9945..5a5429a12b 100644 --- a/lib/ipsec/esp_outb.c +++ b/lib/ipsec/esp_outb.c @@ -196,7 +196,7 @@ outb_tun_pkt_prepare(struct rte_ipsec_sa *sa, rte_be64_t sqc, /* if UDP encap is enabled update the dgram_len */ if (sa->type & RTE_IPSEC_SATP_NATT_ENABLE) { struct rte_udp_hdr *udph = (struct rte_udp_hdr *) - (ph - sizeof(struct rte_udp_hdr)); + (ph + sa->hdr_len - sizeof(struct rte_udp_hdr)); udph->dgram_len = rte_cpu_to_be_16(mb->pkt_len - sqh_len - sa->hdr_l3_off - sa->hdr_len); }