[PATCH] tests/net: fix bind/connect addrlen match for metag
James Hogan
james.hogan at imgtec.com
Wed May 8 08:44:07 UTC 2013
Different architectures can have different sizes of struct sockaddr
which they provide to the addrlen argument of the bind/connect syscalls.
In particular the metag ABI rounds it up to 112 bytes instead of 110.
* tests/net: accept 112 bytes as well as 110 for bind/connect tests.
Signed-off-by: James Hogan <james.hogan at imgtec.com>
---
tests/net | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/net b/tests/net
index 3fb10ba..02742c2 100755
--- a/tests/net
+++ b/tests/net
@@ -38,10 +38,10 @@ grep_log()
grep_log socket '\(PF_(LOCAL|UNIX|FILE), SOCK_STREAM, 0\) += 0'
grep_log socket '\(PF_(LOCAL|UNIX|FILE), SOCK_STREAM, 0\) += 1'
-grep_log bind '\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="local-stream"\}, 110\) += 0'
+grep_log bind '\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="local-stream"\}, (110|112)\) += 0'
grep_log listen '\(0, 5\) += 0'
grep_log getsockname '\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="local-stream"\}, \[15\]\) += 0'
grep_log accept '\(0, \{sa_family=AF_(LOCAL|UNIX|FILE), NULL\}, \[2\]\) += 1'
-grep_log connect '\(1, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="local-stream"\}, 110\) += 0'
+grep_log connect '\(1, \{sa_family=AF_(LOCAL|UNIX|FILE), sun_path="local-stream"\}, (110|112)\) += 0'
exit 0
--
1.8.1.2
More information about the Strace-devel
mailing list