[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20231128-send-net-next-2023107-v4-12-8d6b94150f6b@kernel.org>
Date: Tue, 28 Nov 2023 15:18:56 -0800
From: Mat Martineau <martineau@...nel.org>
To: Matthieu Baerts <matttbe@...nel.org>,
"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>
Cc: netdev@...r.kernel.org, mptcp@...ts.linux.dev,
Mat Martineau <martineau@...nel.org>, Geliang Tang <geliang.tang@...e.com>
Subject: [PATCH net-next v4 12/15] selftests: mptcp: add missing
oflag=append
From: Geliang Tang <geliang.tang@...e.com>
In mptcp_connect.sh we are missing something like "oflag=append"
because this will write "${rem}" bytes at the beginning of the file
where there is already some random bytes. It should write that at
the end.
This patch adds this missing 'oflag=append' flag for 'dd' command in
make_file().
Suggested-by: Matthieu Baerts <matttbe@...nel.org>
Reviewed-by: Matthieu Baerts <matttbe@...nel.org>
Signed-off-by: Geliang Tang <geliang.tang@...e.com>
Signed-off-by: Mat Martineau <martineau@...nel.org>
---
tools/testing/selftests/net/mptcp/mptcp_connect.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/testing/selftests/net/mptcp/mptcp_connect.sh b/tools/testing/selftests/net/mptcp/mptcp_connect.sh
index 3b971d1617d8..c4f08976c418 100755
--- a/tools/testing/selftests/net/mptcp/mptcp_connect.sh
+++ b/tools/testing/selftests/net/mptcp/mptcp_connect.sh
@@ -593,7 +593,7 @@ make_file()
rem=$((SIZE - (ksize * 1024)))
dd if=/dev/urandom of="$name" bs=1024 count=$ksize 2> /dev/null
- dd if=/dev/urandom conv=notrunc of="$name" bs=1 count=$rem 2> /dev/null
+ dd if=/dev/urandom conv=notrunc of="$name" oflag=append bs=1 count=$rem 2> /dev/null
echo -e "\nMPTCP_TEST_FILE_END_MARKER" >> "$name"
echo "Created $name (size $(du -b "$name")) containing data sent by $who"
--
2.43.0
Powered by blists - more mailing lists