summaryrefslogtreecommitdiff
path: root/server/InterfaceController.cpp
diff options
context:
space:
mode:
authorLorenzo Colitti <lorenzo@google.com>2017-02-28 01:47:11 +0900
committerLorenzo Colitti <lorenzo@google.com>2017-03-01 16:38:23 +0900
commita701afb86ea96820c1c916cc374619901927c61a (patch)
tree35b2610204cb1f85e7457715d6aa92fae69a8c41 /server/InterfaceController.cpp
parentfea04a83b5b67aabb31cb08e19b73fa06cfb3993 (diff)
Improve iptables timeout behaviour.
1. Increase the default timeout from 1s to 5s. This is necessary for as long as our version of iptables sleeps for 1 second at a time while the iptables lock is contended. 2. When a timeout occurs, kill the process to ensure that if it recovers, any output is not returned to subsequent commands. Add corresponding unit tests. While I'm at it: - Ensure that iptables commands that take an output string clear the output string before appending to it. Otherwise, callers that passed the same output string object to two separate iptables commands would think the second command returned both outputs. This does not affect any existing callers. - Delete some unused code. Bug: 35634318 Test: netd_{unit,integration}_test pass Change-Id: Ife3dfd328ea82f2e93fb903fcf3660a13078b7b5
Diffstat (limited to 'server/InterfaceController.cpp')
0 files changed, 0 insertions, 0 deletions