Fixed a couple of other minor things too.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10460
// NYI umask_extended 278
DECL_TEMPLATE(darwin, stat_extended); // 279
DECL_TEMPLATE(darwin, lstat_extended); // 280
-// NYI fstat_extended 281
+DECL_TEMPLATE(darwin, fstat_extended); // 281
DECL_TEMPLATE(darwin, chmod_extended); // 282
DECL_TEMPLATE(darwin, fchmod_extended); // 283
// NYI access_extended 284
DECL_TEMPLATE(darwin, lstat64); // 340
DECL_TEMPLATE(darwin, stat64_extended); // 341
DECL_TEMPLATE(darwin, lstat64_extended); // 342
-// NYI fstat64_extended 343
+DECL_TEMPLATE(darwin, fstat64_extended); // 343
DECL_TEMPLATE(darwin, getdirentries64); // 344
DECL_TEMPLATE(darwin, statfs64); // 345
DECL_TEMPLATE(darwin, fstatfs64); // 346
-// NYI getfsstat64 347
+DECL_TEMPLATE(darwin, getfsstat64); // 347
// NYI __pthread_chdir 348
// NYI __pthread_fchdir 349
// NYI audit 350
struct vki_statfs *, buf, int, bufsize, int, flags);
if (ARG1) {
// ARG2 is a BYTE SIZE
- PRE_MEM_WRITE("getfsstat", ARG1, ARG2);
+ PRE_MEM_WRITE("getfsstat(buf)", ARG1, ARG2);
}
}
-
POST(getfsstat)
{
if (ARG1) {
}
}
+PRE(getfsstat64)
+{
+ PRINT("getfsstat64(%#lx, %ld, %ld)", ARG1, ARG2, ARG3);
+ PRE_REG_READ3(int, "getfsstat64",
+ struct vki_statfs64 *, buf, int, bufsize, int, flags);
+ if (ARG1) {
+ // ARG2 is a BYTE SIZE
+ PRE_MEM_WRITE("getfsstat64(buf)", ARG1, ARG2);
+ }
+}
+POST(getfsstat64)
+{
+ if (ARG1) {
+ // RES is a STRUCT COUNT
+ POST_MEM_WRITE(ARG1, RES * sizeof(struct vki_statfs64));
+ }
+}
+
static void scan_attrlist(ThreadId tid, struct vki_attrlist *attrList,
void *attrBuf, SizeT attrBufSize,
vki_pid_t, pid, uint32_t, ops,
void *, useraddr, vki_size_t, usersize);
- PRE_MEM_WRITE( "csops(addr)", ARG3, ARG4 );
+ PRE_MEM_WRITE( "csops(useraddr)", ARG3, ARG4 );
// If the pid is ours, don't mark the program as KILL or HARD
// Maybe we should keep track of this for later calls to STATUS
}
}
}
-
POST(csops)
{
POST_MEM_WRITE( ARG3, ARG4 );
MACXY(__NR_getdirentries64, getdirentries64),
MACXY(__NR_statfs64, statfs64),
MACXY(__NR_fstatfs64, fstatfs64),
-// _____(__NR_getfsstat64),
+ MACXY(__NR_getfsstat64, getfsstat64),
// _____(__NR___pthread_chdir),
// _____(__NR___pthread_fchdir),
// _____(__NR_audit),
GO_UNIMP(17, "old break");
- // __NR_getfsstat 18
+ GO(__NR_getfsstat, 18, "3s 1m");
+ SY(__NR_getfsstat, x0+1, x0+1, x0); SUCC; // This should fail...
GO_UNIMP(19, "old lseek");
// __NR_getdirentries64 344
// __NR_statfs64 345
// __NR_fstatfs64 346
- // __NR_getfsstat64 347
+
+ GO(__NR_getfsstat64, 347, "3s 1m");
+ SY(__NR_getfsstat64, x0+1, x0+1, x0); SUCC; // This should fail...
+
// __NR___pthread_chdir 348
// __NR___pthread_fchdir 349
// __NR_audit 350
(17): old break
-----------------------------------------------------
-----------------------------------------------------
+x2000012(18): __NR_getfsstat 3s 1m
+-----------------------------------------------------
+
+Syscall param getfsstat(buf) contains uninitialised byte(s)
+ ...
+
+Syscall param getfsstat(bufsize) contains uninitialised byte(s)
+ ...
+
+Syscall param getfsstat(flags) contains uninitialised byte(s)
+ ...
+
+Syscall param getfsstat(buf) points to unaddressable byte(s)
+ ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+-----------------------------------------------------
(19): old lseek
-----------------------------------------------------
-----------------------------------------------------
Syscall param csops(usersize) contains uninitialised byte(s)
...
-Syscall param csops(addr) points to unaddressable byte(s)
+Syscall param csops(useraddr) points to unaddressable byte(s)
...
Address 0x........ is not stack'd, malloc'd or (recently) free'd
-----------------------------------------------------
x2000117(279): __NR_stat_extended 4s 4m
-----------------------------------------------------
+More than 100 errors detected. Subsequent errors
+will still be recorded, but in less detail than before.
+
Syscall param stat_extended(file_name) contains uninitialised byte(s)
...
Syscall param stat_extended(fsacl_size) contains uninitialised byte(s)
...
-More than 100 errors detected. Subsequent errors
-will still be recorded, but in less detail than before.
-
Syscall param stat_extended(file_name) points to unaddressable byte(s)
...
Address 0x........ is not stack'd, malloc'd or (recently) free'd
...
Address 0x........ is not stack'd, malloc'd or (recently) free'd
-----------------------------------------------------
+x200015b(347): __NR_getfsstat64 3s 1m
+-----------------------------------------------------
+
+Syscall param getfsstat64(buf) contains uninitialised byte(s)
+ ...
+
+Syscall param getfsstat64(bufsize) contains uninitialised byte(s)
+ ...
+
+Syscall param getfsstat64(flags) contains uninitialised byte(s)
+ ...
+
+Syscall param getfsstat64(buf) points to unaddressable byte(s)
+ ...
+ Address 0x........ is not stack'd, malloc'd or (recently) free'd
+-----------------------------------------------------
(369-379): unused
-----------------------------------------------------
-----------------------------------------------------