Code Review
/
icn
/
sdwan.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
7b00dd6
)
Fix wrong value usage
94/4694/1
author
Le Yao
<le.yao@intel.com>
Thu, 17 Feb 2022 01:19:08 +0000
(20:19 -0500)
committer
Le Yao
<le.yao@intel.com>
Thu, 17 Feb 2022 01:20:13 +0000
(20:20 -0500)
Signed-off-by: Le Yao <le.yao@intel.com>
Change-Id: Ibf59509620bd7d7d62a492ea3b28f5d21e653dee
platform/cnf-openwrt/src/rest_v1/nat_rest.lua
patch
|
blob
|
history
diff --git
a/platform/cnf-openwrt/src/rest_v1/nat_rest.lua
b/platform/cnf-openwrt/src/rest_v1/nat_rest.lua
index
629240c
..
fb60b9f
100644
(file)
--- a/
platform/cnf-openwrt/src/rest_v1/nat_rest.lua
+++ b/
platform/cnf-openwrt/src/rest_v1/nat_rest.lua
@@
-50,8
+50,8
@@
function check_nat(value)
if value["dest"] == nil then
return false, "dest is required for SNAT"
end
- if
dest
== "#source" then
-
dest = ifutil.get_name_by_ip(src_dip
)
+ if
value["dest"]
== "#source" then
+
local dest = ifutil.get_name_by_ip(value["src_dip"]
)
if dest == nil or dest == "" then
return false, "428:ip not found on all interfaces"
end