Newer Linux architectures don't support the stat/stat64 syscalls.
Instead they use fstatat() with AT_FDCWD and an extra flags argument.
Support seeing this output in the 'strace -efile' test.

Signed-off-by: Chris Metcalf <[email protected]>
---
Note that the two strace -efiles tests ("find" and "find -L") actually
produce the same strace output on such platforms (other than seeing
the NOFOLLOW flag in one case).  I'm not sure making all the "AT_FDCWD",
etc., stuff explicit in the regexp really makes the most sense or not,
but it seemed closest to the spirit of the original regexp code.

 tests/stat |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/stat b/tests/stat
index 5fe0b86..3f006a2 100755
--- a/tests/stat
+++ b/tests/stat
@@ -27,7 +27,7 @@ LC_ALL=C grep -x 'lseek(1, 46118400000, SEEK_CUR) \+= 
46118400000\|_llseek(1, 46
 
 timeout -s 9 $check_timeout \
 $STRACE -efile find -L sample > /dev/null 2> check.log &&
-LC_ALL=C grep -x 'stat\(64\)\?("sample", {st_mode=S_IFREG|0644, 
st_size=46118400000, \.\.\.}) \+= 0' check.log > /dev/null ||
+LC_ALL=C grep -x 'f\?stat\(at\)\?\(64\)\?(\(AT_FDCWD, \)\?"sample", 
{st_mode=S_IFREG|0644, st_size=46118400000, \.\.\.}\(, 0\)\?) \+= 0' check.log 
> /dev/null ||
        { cat check.log; fail_ 'strace -efile failed to trace stat/stat64 
properly'; }
 
 timeout -s 9 $check_timeout \
-- 
1.7.10.3


------------------------------------------------------------------------------
Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET
Get 100% visibility into your production application - at no cost.
Code-level diagnostics for performance bottlenecks with <2% overhead
Download for free and get started troubleshooting in minutes.
http://p.sf.net/sfu/appdyn_d2d_ap1
_______________________________________________
Strace-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/strace-devel

Reply via email to