ChangeLog, pass1.c:
  pass1.c (check_blocks): Fix large file checking code so that files >
  	2GB are considered large files, and restrict directories from being >
  	2GB.
version.h:
  Update for WIP release.

diff --git a/e2fsck/ChangeLog b/e2fsck/ChangeLog
index eb48f31..1e5f8a3 100644
--- a/e2fsck/ChangeLog
+++ b/e2fsck/ChangeLog
@@ -1,3 +1,9 @@
+2001-01-17  Theodore Ts'o  <tytso@valinux.com>
+
+	* pass1.c (check_blocks): Fix large file checking code so that
+		files > 2GB are considered large files, and restrict
+		directories from being > 2GB.
+
 2001-01-12  Theodore Ts'o  <tytso@valinux.com>
 
 	* journal.c (e2fsck_journal_fix_unsupported_super): Remove unused
diff --git a/e2fsck/pass1.c b/e2fsck/pass1.c
index 1999532..99a88b0 100644
--- a/e2fsck/pass1.c
+++ b/e2fsck/pass1.c
@@ -923,8 +923,9 @@
 	}
 	if (pb.is_dir) {
 		int nblock = inode->i_size >> EXT2_BLOCK_SIZE_BITS(fs->super);
-		if ((nblock > (pb.last_block + 1)) ||
-		    ((inode->i_size & (fs->blocksize-1)) != 0))
+		/* We don't let a directory become larger than 2GB */
+		if (nblock > (pb.last_block + 1) ||
+		    (inode->i_size & ((fs->blocksize-1) | 0x80000000UL)) != 0)
 			bad_size = 1;
 		else if (nblock < (pb.last_block + 1)) {
 			if (((pb.last_block + 1) - nblock) >
@@ -932,11 +933,12 @@
 				bad_size = 2;
 		}
 	} else {
-		size = inode->i_size + ((__u64) inode->i_size_high << 32);
+		size = inode->i_size | ((__u64) inode->i_size_high << 32);
 		if ((size < pb.last_block * fs->blocksize))
 			bad_size = 3;
 		else if (size > ext2_max_sizes[fs->super->s_log_block_size])
 			bad_size = 4;
+		/* FIXME: need to ensure pb.num_blocks < 2^32 */
 	}
 	if (bad_size) {
 		pctx->num = (pb.last_block+1) * fs->blocksize;
@@ -948,7 +950,7 @@
 		}
 		pctx->num = 0;
 	}
-	if (!pb.is_dir && inode->i_size_high)
+	if (!pb.is_dir && (inode->i_size_high || inode->i_size & 0x80000000UL))
 		ctx->large_files++;
 	if (pb.num_blocks != inode->i_blocks) {
 		pctx->num = pb.num_blocks;
diff --git a/version.h b/version.h
index fbee604..320a355 100644
--- a/version.h
+++ b/version.h
@@ -7,4 +7,4 @@
  */
 
 #define E2FSPROGS_VERSION "1.20-WIP"
-#define E2FSPROGS_DATE "03-Jan-2001"
+#define E2FSPROGS_DATE "17-Jan-2001"