alpha: fix decoding of osf_statfs and osf_fstatfs syscalls
Do not attempt to print struct osf_statfs as if it was the same as
struct statfs. Since struct osf_statfs has never been decoded properly,
it is probably too late to implement a decoder, so let's just print the
pointer.
* statfs.c [ALPHA] (SYS_FUNC(osf_statfs), SYS_FUNC(osf_fstatfs)): Move ...
* alpha.c: ... here. Replace printstatfs with printaddr.
diff --git a/alpha.c b/alpha.c
index e343b7e..70d4ca5 100644
--- a/alpha.c
+++ b/alpha.c
@@ -60,4 +60,24 @@
return decode_getxxid(tcp, "egid");
}
+SYS_FUNC(osf_statfs)
+{
+ printpath(tcp, tcp->u_arg[0]);
+ tprints(", ");
+ printaddr(tcp->u_arg[1]);
+ tprints(", ");
+ tprintf("%lu", tcp->u_arg[2]);
+ return RVAL_DECODED;
+}
+
+SYS_FUNC(osf_fstatfs)
+{
+ printfd(tcp, tcp->u_arg[0]);
+ tprints(", ");
+ printaddr(tcp->u_arg[1]);
+ tprints(", ");
+ tprintf("%lu", tcp->u_arg[2]);
+ return RVAL_DECODED;
+}
+
#endif /* ALPHA */
diff --git a/statfs.c b/statfs.c
index 73892b6..bcbb73d 100644
--- a/statfs.c
+++ b/statfs.c
@@ -217,28 +217,3 @@
return do_statfs64_fstatfs64(tcp);
}
#endif /* HAVE_STRUCT_STATFS64 */
-
-#ifdef ALPHA
-SYS_FUNC(osf_statfs)
-{
- if (entering(tcp)) {
- printpath(tcp, tcp->u_arg[0]);
- tprints(", ");
- } else {
- printstatfs(tcp, tcp->u_arg[1]);
- tprintf(", %lu", tcp->u_arg[2]);
- }
- return 0;
-}
-
-SYS_FUNC(osf_fstatfs)
-{
- if (entering(tcp)) {
- tprintf("%lu, ", tcp->u_arg[0]);
- } else {
- printstatfs(tcp, tcp->u_arg[1]);
- tprintf(", %lu", tcp->u_arg[2]);
- }
- return 0;
-}
-#endif /* ALPHA */