diff options
author | cy <cy@FreeBSD.org> | 2017-06-06 19:20:28 +0000 |
---|---|---|
committer | cy <cy@FreeBSD.org> | 2017-06-06 19:20:28 +0000 |
commit | 5e738e821a7fa6aacacb7025c58ba730119d70a6 (patch) | |
tree | 210b2a2fd438ebdda11e2eb781712017c23977a6 /sys/contrib/ipfilter | |
parent | 2f8449604df8c5b099c9ad330e3e93f4cacdf0e4 (diff) | |
download | FreeBSD-src-5e738e821a7fa6aacacb7025c58ba730119d70a6.zip FreeBSD-src-5e738e821a7fa6aacacb7025c58ba730119d70a6.tar.gz |
MFC r318998:
Fix return value of ip_sync_nat. Previously, regardless of error it
always returned a return code of 0.
Obtained from: NetBSD ip_sync.c r1.5
Approved by: re (delphij)
Diffstat (limited to 'sys/contrib/ipfilter')
-rw-r--r-- | sys/contrib/ipfilter/netinet/ip_sync.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/contrib/ipfilter/netinet/ip_sync.c b/sys/contrib/ipfilter/netinet/ip_sync.c index 0c2fe10..5909409 100644 --- a/sys/contrib/ipfilter/netinet/ip_sync.c +++ b/sys/contrib/ipfilter/netinet/ip_sync.c @@ -939,7 +939,7 @@ ipf_sync_nat(softc, sp, data) nat_t *n, *nat; synclist_t *sl; u_int hv = 0; - int err; + int err = 0; READ_ENTER(&softs->ipf_syncnat); @@ -1016,7 +1016,7 @@ ipf_sync_nat(softc, sp, data) } RWLOCK_EXIT(&softs->ipf_syncnat); - return 0; + return err; } |