/[linux-patches]/genpatches-2.6/tags/2.6.14-5/1105_invalidate-inodes-overflow.patch
Gentoo

Contents of /genpatches-2.6/tags/2.6.14-5/1105_invalidate-inodes-overflow.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 226 - (show annotations) (download)
Fri Dec 2 12:14:55 2005 UTC (12 years, 6 months ago) by dsd
File size: 1244 byte(s)
2.6.14-5 release
1 From: Oleg Drokin <green@linuxhacker.ru>
2 Date: Wed, 23 Nov 2005 21:37:47 +0000 (-0800)
3 Subject: [PATCH] 32bit integer overflow in invalidate_inode_pages2()
4 X-Git-Tag: v2.6.15-rc3
5 X-Git-Url: http://www.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=479ef592f3664dd629417098c8599261c0f689ab
6
7 [PATCH] 32bit integer overflow in invalidate_inode_pages2()
8
9 Fix a 32 bit integer overflow in invalidate_inode_pages2_range.
10
11 Signed-off-by: Andrew Morton <akpm@osdl.org>
12 Signed-off-by: Linus Torvalds <torvalds@osdl.org>
13 ---
14
15 --- a/mm/truncate.c
16 +++ b/mm/truncate.c
17 @@ -282,8 +282,8 @@ int invalidate_inode_pages2_range(struct
18 * Zap the rest of the file in one hit.
19 */
20 unmap_mapping_range(mapping,
21 - page_index << PAGE_CACHE_SHIFT,
22 - (end - page_index + 1)
23 + (loff_t)page_index<<PAGE_CACHE_SHIFT,
24 + (loff_t)(end - page_index + 1)
25 << PAGE_CACHE_SHIFT,
26 0);
27 did_range_unmap = 1;
28 @@ -292,7 +292,7 @@ int invalidate_inode_pages2_range(struct
29 * Just zap this page
30 */
31 unmap_mapping_range(mapping,
32 - page_index << PAGE_CACHE_SHIFT,
33 + (loff_t)page_index<<PAGE_CACHE_SHIFT,
34 PAGE_CACHE_SIZE, 0);
35 }
36 }

  ViewVC Help
Powered by ViewVC 1.1.20