diff --git a/kernel/fs.h b/kernel/fs.h index 139dcc9c37..05575b5fcd 100644 --- a/kernel/fs.h +++ b/kernel/fs.h @@ -51,10 +51,11 @@ struct dinode { #define BBLOCK(b, sb) ((b)/BPB + sb.bmapstart) // Directory is a file containing a sequence of dirent structures. -#define DIRSIZ 14 +// Setting DIRSIZ to 12 makes sizeof(struct dirent) a multiple of 16. +#define DIRSIZ 12 struct dirent { - ushort inum; + uint inum; char name[DIRSIZ]; };