From 6011e1603e5988609d691111b98edce88d2105a2 Mon Sep 17 00:00:00 2001 From: Anton Altaparmakov Date: Thu, 8 Sep 2005 16:52:31 +0100 Subject: [PATCH] --- yaml --- r: 7759 b: refs/heads/master c: 2b0ada2b8e086c267dd116a39ad41ff0a717b665 h: refs/heads/master i: 7757: 7183a53bb77460beb8983d9db7a539bda255a550 7755: ac5c945fe88b41298db660b53870556370d0833f 7751: f942bd4e20b4211ce3bd5f2f9be49753bc7b92cd 7743: e5c3c2712dc67565ea61658b8ec03345ae1a0448 v: v3 --- [refs] | 2 +- trunk/fs/ntfs/ChangeLog | 2 ++ trunk/fs/ntfs/runlist.c | 3 +++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 409aab7b19fc..22b19a551bf2 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 8bb735216a0675e247bbe8b8b92c09d6884d1a17 +refs/heads/master: 2b0ada2b8e086c267dd116a39ad41ff0a717b665 diff --git a/trunk/fs/ntfs/ChangeLog b/trunk/fs/ntfs/ChangeLog index f4c27f7c1b6a..8fe38c801166 100644 --- a/trunk/fs/ntfs/ChangeLog +++ b/trunk/fs/ntfs/ChangeLog @@ -46,6 +46,8 @@ ToDo/Notes: - Fix two nasty runlist merging bugs that had gone unnoticed so far. Thanks to Stefano Picerno for the bug report. - Remove two bogus BUG_ON()s from fs/ntfs/mft.c. + - Fix handling of valid but empty mapping pairs array in + fs/ntfs/runlist.c::ntfs_mapping_pairs_decompress(). 2.1.23 - Implement extension of resident files and make writing safe as well as many bug fixes, cleanups, and enhancements... diff --git a/trunk/fs/ntfs/runlist.c b/trunk/fs/ntfs/runlist.c index d26a1be530c5..e4c4716939de 100644 --- a/trunk/fs/ntfs/runlist.c +++ b/trunk/fs/ntfs/runlist.c @@ -760,6 +760,9 @@ runlist_element *ntfs_mapping_pairs_decompress(const ntfs_volume *vol, ntfs_error(vol->sb, "Corrupt attribute."); return ERR_PTR(-EIO); } + /* If the mapping pairs array is valid but empty, nothing to do. */ + if (!vcn && !*buf) + return old_rl; /* Current position in runlist array. */ rlpos = 0; /* Allocate first page and set current runlist size to one page. */