From: Alexey Dobriyan Date: Sat, 2 Aug 2008 03:30:48 +0000 (+0400) Subject: [PATCH] proc: inode number fixlet X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=cc996099174dc05b35b7a29301026987990e7f8c;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git [PATCH] proc: inode number fixlet Ouch, if number taken from IDA is too big, the intent was to signal an error, not check for overflow and still do overflowing addition. One still needs 2^28 proc entries to notice this. Signed-off-by: Alexey Dobriyan Signed-off-by: Al Viro --- diff --git a/fs/proc/generic.c b/fs/proc/generic.c index 4fb81e9c94e3..bca0f81eb687 100644 --- a/fs/proc/generic.c +++ b/fs/proc/generic.c @@ -330,6 +330,7 @@ retry: spin_lock(&proc_inum_lock); ida_remove(&proc_inum_ida, i); spin_unlock(&proc_inum_lock); + return 0; } return PROC_DYNAMIC_FIRST + i; }