diff options
-rw-r--r-- | fs/ntfs/ChangeLog | 6 | ||||
-rw-r--r-- | fs/ntfs/Makefile | 2 | ||||
-rw-r--r-- | fs/ntfs/namei.c | 2 | ||||
-rw-r--r-- | fs/ntfs/runlist.c | 12 | ||||
-rw-r--r-- | fs/ntfs/super.c | 2 |
5 files changed, 17 insertions, 7 deletions
diff --git a/fs/ntfs/ChangeLog b/fs/ntfs/ChangeLog index 9d8ffa89e2c..3d8d60be48d 100644 --- a/fs/ntfs/ChangeLog +++ b/fs/ntfs/ChangeLog | |||
@@ -19,6 +19,12 @@ ToDo/Notes: | |||
19 | - Enable the code for setting the NT4 compatibility flag when we start | 19 | - Enable the code for setting the NT4 compatibility flag when we start |
20 | making NTFS 1.2 specific modifications. | 20 | making NTFS 1.2 specific modifications. |
21 | 21 | ||
22 | 2.1.27 - Various bug fixes. | ||
23 | |||
24 | - Fix two compiler warnings on Alpha. Thanks to Andrew Morton for | ||
25 | reporting them. | ||
26 | - Fix an (innocent) off-by-one error in the runlist code. | ||
27 | |||
22 | 2.1.26 - Minor bug fixes and updates. | 28 | 2.1.26 - Minor bug fixes and updates. |
23 | 29 | ||
24 | - Fix a potential overflow in file.c where a cast to s64 was missing in | 30 | - Fix a potential overflow in file.c where a cast to s64 was missing in |
diff --git a/fs/ntfs/Makefile b/fs/ntfs/Makefile index d95fac7fdeb..e27b4eacffb 100644 --- a/fs/ntfs/Makefile +++ b/fs/ntfs/Makefile | |||
@@ -6,7 +6,7 @@ ntfs-objs := aops.o attrib.o collate.o compress.o debug.o dir.o file.o \ | |||
6 | index.o inode.o mft.o mst.o namei.o runlist.o super.o sysctl.o \ | 6 | index.o inode.o mft.o mst.o namei.o runlist.o super.o sysctl.o \ |
7 | unistr.o upcase.o | 7 | unistr.o upcase.o |
8 | 8 | ||
9 | EXTRA_CFLAGS = -DNTFS_VERSION=\"2.1.26\" | 9 | EXTRA_CFLAGS = -DNTFS_VERSION=\"2.1.27\" |
10 | 10 | ||
11 | ifeq ($(CONFIG_NTFS_DEBUG),y) | 11 | ifeq ($(CONFIG_NTFS_DEBUG),y) |
12 | EXTRA_CFLAGS += -DDEBUG | 12 | EXTRA_CFLAGS += -DDEBUG |
diff --git a/fs/ntfs/namei.c b/fs/ntfs/namei.c index 5ea9eb93af6..78e0cf738e2 100644 --- a/fs/ntfs/namei.c +++ b/fs/ntfs/namei.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * namei.c - NTFS kernel directory inode operations. Part of the Linux-NTFS | 2 | * namei.c - NTFS kernel directory inode operations. Part of the Linux-NTFS |
3 | * project. | 3 | * project. |
4 | * | 4 | * |
5 | * Copyright (c) 2001-2004 Anton Altaparmakov | 5 | * Copyright (c) 2001-2006 Anton Altaparmakov |
6 | * | 6 | * |
7 | * This program/include file is free software; you can redistribute it and/or | 7 | * This program/include file is free software; you can redistribute it and/or |
8 | * modify it under the terms of the GNU General Public License as published | 8 | * modify it under the terms of the GNU General Public License as published |
diff --git a/fs/ntfs/runlist.c b/fs/ntfs/runlist.c index 061b5ff6b73..eb52b801512 100644 --- a/fs/ntfs/runlist.c +++ b/fs/ntfs/runlist.c | |||
@@ -381,6 +381,7 @@ static inline runlist_element *ntfs_rl_insert(runlist_element *dst, | |||
381 | static inline runlist_element *ntfs_rl_replace(runlist_element *dst, | 381 | static inline runlist_element *ntfs_rl_replace(runlist_element *dst, |
382 | int dsize, runlist_element *src, int ssize, int loc) | 382 | int dsize, runlist_element *src, int ssize, int loc) |
383 | { | 383 | { |
384 | signed delta; | ||
384 | BOOL left = FALSE; /* Left end of @src needs merging. */ | 385 | BOOL left = FALSE; /* Left end of @src needs merging. */ |
385 | BOOL right = FALSE; /* Right end of @src needs merging. */ | 386 | BOOL right = FALSE; /* Right end of @src needs merging. */ |
386 | int tail; /* Start of tail of @dst. */ | 387 | int tail; /* Start of tail of @dst. */ |
@@ -396,11 +397,14 @@ static inline runlist_element *ntfs_rl_replace(runlist_element *dst, | |||
396 | left = ntfs_are_rl_mergeable(dst + loc - 1, src); | 397 | left = ntfs_are_rl_mergeable(dst + loc - 1, src); |
397 | /* | 398 | /* |
398 | * Allocate some space. We will need less if the left, right, or both | 399 | * Allocate some space. We will need less if the left, right, or both |
399 | * ends get merged. | 400 | * ends get merged. The -1 accounts for the run being replaced. |
400 | */ | 401 | */ |
401 | dst = ntfs_rl_realloc(dst, dsize, dsize + ssize - left - right); | 402 | delta = ssize - 1 - left - right; |
402 | if (IS_ERR(dst)) | 403 | if (delta > 0) { |
403 | return dst; | 404 | dst = ntfs_rl_realloc(dst, dsize, dsize + delta); |
405 | if (IS_ERR(dst)) | ||
406 | return dst; | ||
407 | } | ||
404 | /* | 408 | /* |
405 | * We are guaranteed to succeed from here so can start modifying the | 409 | * We are guaranteed to succeed from here so can start modifying the |
406 | * original runlists. | 410 | * original runlists. |
diff --git a/fs/ntfs/super.c b/fs/ntfs/super.c index 368a8ec1066..71c58eca580 100644 --- a/fs/ntfs/super.c +++ b/fs/ntfs/super.c | |||
@@ -3234,7 +3234,7 @@ static void __exit exit_ntfs_fs(void) | |||
3234 | } | 3234 | } |
3235 | 3235 | ||
3236 | MODULE_AUTHOR("Anton Altaparmakov <aia21@cantab.net>"); | 3236 | MODULE_AUTHOR("Anton Altaparmakov <aia21@cantab.net>"); |
3237 | MODULE_DESCRIPTION("NTFS 1.2/3.x driver - Copyright (c) 2001-2005 Anton Altaparmakov"); | 3237 | MODULE_DESCRIPTION("NTFS 1.2/3.x driver - Copyright (c) 2001-2006 Anton Altaparmakov"); |
3238 | MODULE_VERSION(NTFS_VERSION); | 3238 | MODULE_VERSION(NTFS_VERSION); |
3239 | MODULE_LICENSE("GPL"); | 3239 | MODULE_LICENSE("GPL"); |
3240 | #ifdef DEBUG | 3240 | #ifdef DEBUG |