nat: fix type in api message 96/27796/5
authorKlement Sekera <ksekera@cisco.com>
Mon, 6 Jul 2020 09:20:01 +0000 (09:20 +0000)
committerMatthew Smith <mgsmith@netgate.com>
Mon, 31 Aug 2020 21:52:42 +0000 (21:52 +0000)
commitedc816355a999df476074881ae8ed927cad88532
tree76845b254e8801593a7ca2e53b6bc489b66aa810
parentb59095f830fbacbe2631dbbaa92f8e9606184015
nat: fix type in api message

Translation memory size is internally a uword, but in api it was u32,
resulting in the returned value being 0 all the time.

Fix the "incorrect" API reply to return a u32 capped to 0xffffffff if
the u64 is larger than that, introduce the message with
the correct type, deprecate the message with the incorrect type.

Also, while we are updating the message definition,
add the max translations / max users per worker thread
into the new message.

Type: fix
Signed-off-by: Klement Sekera <ksekera@cisco.com>
Change-Id: I92e38a6a2bcb70fc8d1b129bbe416bf7f9e54280
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
src/plugins/nat/nat.api
src/plugins/nat/nat_api.c
src/plugins/nat/nat_test.c
src/plugins/nat/test/test_nat.py