[PATCH 18/20] Re: [2.6-BK-URL] NTFS 2.1.17 release

From: Anton Altaparmakov
Date: Mon Aug 23 2004 - 06:14:45 EST


This is patch 18/20 in the series. It contains the following ChangeSet:

<aia21@xxxxxxxxxx> (04/08/17 1.1824)
NTFS: Only need two spare runlist elements when reallocating memory in
fs/ntfs/lcnalloc.c::ntfs_cluster_alloc(), not three since we no longer
add a starting element.

Signed-off-by: Anton Altaparmakov <aia21@xxxxxxxxxx>

Best regards,

Anton
--
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Unix Support, Computing Service, University of Cambridge, CB2 3QH, UK
Linux NTFS maintainer / IRC: #ntfs on irc.freenode.net
WWW: http://linux-ntfs.sf.net/, http://www-stu.christs.cam.ac.uk/~aia21/

===================================================================

diff -Nru a/fs/ntfs/lcnalloc.c b/fs/ntfs/lcnalloc.c
--- a/fs/ntfs/lcnalloc.c 2004-08-18 20:50:44 +01:00
+++ b/fs/ntfs/lcnalloc.c 2004-08-18 20:50:44 +01:00
@@ -322,10 +322,10 @@
}
/*
* Allocate more memory if needed, including space for
- * the not-mapped and terminator elements.
+ * the terminator element.
* ntfs_malloc_nofs() operates on whole pages only.
*/
- if ((rlpos + 3) * sizeof(*rl) > rlsize) {
+ if ((rlpos + 2) * sizeof(*rl) > rlsize) {
runlist_element *rl2;

ntfs_debug("Reallocating memory.");
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/