W dniu 06.05.2020 o 11:02, Praveen Shetty pisze: > Function create_ipsec_esp_flow returns a negative number in case of any > failure. But passing negative number to strerror is causing the coverity > issue. > In case of failure, displaying exact error message to console is handled > in create_ipsec_esp_flow function.So it is not required to print the > error message again using strerror. > This patch will remove the unnecessary calling of strerror function > to fix the coverity issue. > > Coverity issue: 357691 > Fixes: 6738c0a95695 ("examples/ipsec-secgw: support flow director") > Cc: praveen.she...@intel.com > > Signed-off-by: Praveen Shetty <praveen.she...@intel.com> > --- > examples/ipsec-secgw/sa.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/examples/ipsec-secgw/sa.c b/examples/ipsec-secgw/sa.c > index e3a1a5aff..632482176 100644 > --- a/examples/ipsec-secgw/sa.c > +++ b/examples/ipsec-secgw/sa.c > @@ -1223,8 +1223,7 @@ sa_add_rules(struct sa_ctx *sa_ctx, const struct > ipsec_sa entries[], > rc = create_ipsec_esp_flow(sa); > if (rc != 0) > RTE_LOG(ERR, IPSEC_ESP, > - "create_ipsec_esp_flow() failed %s\n", > - strerror(rc)); > + "create_ipsec_esp_flow() failed\n"); > } > print_one_sa_rule(sa, inbound); > }
great!, especially that create_ipsec_esp_flow returns mostly -1 in case of errors and that would be -EPERM ;) Acked-by: Lukasz Wojciechowski <l.wojciec...@partner.samsung.com> -- Lukasz Wojciechowski Principal Software Engineer Samsung R&D Institute Poland Samsung Electronics Office +48 22 377 88 25 l.wojciec...@partner.samsung.com