Skip to contentSkip to conversation

linux-2.5.18: fs/hfs/inode.c: PATCH to fix compilation error

PATCH Steven Augart 1 participant 1 message May 30, 2002 HFS filesystem

lore
Share & tools
lore
#0 lore raw

Subject: Patch to fix compilation error in linux-2.5.18/fs/hfs/inode.c

This patch fixes a compilation error in linux-2.5.18/fs/hfs/inode.c, where gcc 2.95.3 complains that it does not have a complete definition
for `struct page' in hfs_prepare_write(). The exact error message
given is:

inode.c: In function `hfs_prepare_write':
inode.c:242: dereferencing pointer to incomplete type

To give credit where due, after I fixed this bug I found that suggested fixes have also been sent in by
Alexander Viro <[email protected]>, by Christoph Hellwig <[email protected]>, and by Jan Harkes <[email protected]>

The compilation problem has already been reported by Brad Littlejohn <[email protected]> and John Weber <[email protected]>.

Steven Augart
[email protected]

fs/hfs/inode.c Tue May 28 17:23:06 2002 renamed from fs/hfs/inode.c Thu May 9 15:24:20 2002 +1 -0
diff -ur linux-2.5.18/fs/hfs/inode.c linux-2.5.18+/fs/hfs/inode.c
@@ -21,6 +21,7 @@
 #include <linux/hfs_fs_i.h>
 #include <linux/hfs_fs.h>
 #include <linux/smp_lock.h>
+#include <linux/mm.h>          /* for struct page */
 
 /*================ Variable-like macros ================*/