提交 a3005b0f 编写于 作者: F Fabian Frederick 提交者: Pablo Neira Ayuso

selftests: netfilter: fix current year

use date %Y instead of %G to read current year
Problem appeared when running lkp-tests on 01/01/2021

Fixes: 48d072c4 ("selftests: netfilter: add time counter check")
Reported-by: Nkernel test robot <oliver.sang@intel.com>
Signed-off-by: NFabian Frederick <fabf@skynet.be>
Signed-off-by: NPablo Neira Ayuso <pablo@netfilter.org>
上级 b1bdde33
......@@ -23,7 +23,7 @@ ip -net "$ns0" addr add 127.0.0.1 dev lo
trap cleanup EXIT
currentyear=$(date +%G)
currentyear=$(date +%Y)
lastyear=$((currentyear-1))
ip netns exec "$ns0" nft -f /dev/stdin <<EOF
table inet filter {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册