Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

selftests: rtnetlink: clear the return code at start of ipsec test

Following the custom from the other functions, clear the global
ret code before starting the test so as to not have previously
failed tests cause us to thing this test has failed.

Reported-by: Anders Roxell <anders.roxell@linaro.org>
Signed-off-by: Shannon Nelson <shannon.nelson@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Shannon Nelson and committed by
David S. Miller
fd0e418d a408194a

+2
+2
tools/testing/selftests/net/rtnetlink.sh
··· 525 525 #------------------------------------------------------------------- 526 526 kci_test_ipsec() 527 527 { 528 + ret=0 529 + 528 530 # find an ip address on this machine and make up a destination 529 531 srcip=`ip -o addr | awk '/inet / { print $4; }' | grep -v "^127" | head -1 | cut -f1 -d/` 530 532 net=`echo $srcip | cut -f1-3 -d.`