summaryrefslogtreecommitdiffstats
path: root/fs/proc/link.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/proc/link.c')
-rw-r--r--fs/proc/link.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/proc/link.c b/fs/proc/link.c
index 70c31f21a..b12050767 100644
--- a/fs/proc/link.c
+++ b/fs/proc/link.c
@@ -158,7 +158,7 @@ static int do_proc_readlink(struct dentry *dentry, char * buffer, int buflen)
path = tmp;
} else {
path = d_path(dentry, tmp, PAGE_SIZE);
- len = tmp + PAGE_SIZE - path;
+ len = tmp + PAGE_SIZE - 1 - path;
}
if (len < buflen)