From c38e3491171d1f7db51d417e1853383bf5dc67a7 Mon Sep 17 00:00:00 2001 From: szaka Date: Thu, 15 Nov 2007 07:21:43 +0000 Subject: [PATCH] ntfs_readdir(): fix reading dirs over 600,000 files (GeorgeK, Szaka) --- libntfs-3g/dir.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libntfs-3g/dir.c b/libntfs-3g/dir.c index c14c3fbc..6822b03e 100644 --- a/libntfs-3g/dir.c +++ b/libntfs-3g/dir.c @@ -883,6 +883,7 @@ find_next_index_buffer: if (bmp_buf_pos >> 3 < bmp_buf_size) continue; /* Read next chunk from the index bitmap. */ + bmp_buf_pos = 0; if ((bmp_pos >> 3) + bmp_buf_size > bmp_na->data_size) bmp_buf_size = bmp_na->data_size - (bmp_pos >> 3); br = ntfs_attr_pread(bmp_na, bmp_pos >> 3, bmp_buf_size, bmp);