]> granicus.if.org Git - strace/commitdiff
Add patch from drow to get proper kernel types in file.c
authorWichert Akkerman <wichert@deephackmode.org>
Thu, 8 Jul 1999 14:00:58 +0000 (14:00 +0000)
committerWichert Akkerman <wichert@deephackmode.org>
Thu, 8 Jul 1999 14:00:58 +0000 (14:00 +0000)
ChangeLog
TODO
file.c

index f71bd4b8dcafe5347feffd5acd5dd54198581200..575d33f257d5b15f0aeb0610a9d5e4ef5989f809 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,8 +1,13 @@
-Thu Jun 24 15:54:18 CEST 1999
+Thu Jul  8 16:00:04 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
+
+  * Merge patch from Daniel Jacobowitz to allow us to use the kernel types
+    for the stat structure
+
+Thu Jun 24 15:54:18 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
 
   * Fix test for sys/reg include
 
-Tue Jun 22 17:26:33 CEST 1999
+Tue Jun 22 17:26:33 CEST 1999 Wichert Akkerman <wakkerma@debian.org>
 
   * Fixed some Linux/powerpc sillyness, thanks to Daniel Jacobowitz
   * Fixed some SunOS compile problems earlier that I forgot to include
diff --git a/TODO b/TODO
index ae11ae886af4362f7e17dc027c8fc8fa22fb03c0..ecc38fbccf14f95a2631be195db60cb6c7f0a3ab 100644 (file)
--- a/TODO
+++ b/TODO
@@ -1,7 +1,7 @@
 -- new entries from wta
-getdents has wrong structure; track down kernel version
 clone doesn't work; cloned processes can hang
 replace printargs with something that reads a configuration-file
+-> rescheduled for strace rewrite
 rename functions that are used for general things:
   sys_chdir -> general_1stringarg
 generate syscallent.h from the kernel sources
diff --git a/file.c b/file.c
index bb5f9c6f0b9d58e63d534357b4fe26792f8323da..2a7c8fbdea3e6f2ddfbb607b20e780d57321bc60 100644 (file)
--- a/file.c
+++ b/file.c
@@ -66,7 +66,25 @@ struct stat {
 #    include <asm/stat.h>
 #    undef stat
 #  else
+#    define dev_t __kernel_dev_t
+#    define ino_t __kernel_ino_t
+#    define mode_t __kernel_mode_t
+#    define nlink_t __kernel_nlink_t
+#    define uid_t __kernel_uid_t
+#    define gid_t __kernel_gid_t
+#    define off_t __kernel_off_t
+#    define loff_t __kernel_loff_t
+
 #    include <asm/stat.h>
+
+#    undef dev_t
+#    undef ino_t
+#    undef mode_t
+#    undef nlink_t
+#    undef uid_t
+#    undef gid_t
+#    undef off_t
+#    undef loff_t
 #  endif
 #  define stat libc_stat
 #  include <sys/stat.h>