diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/compat.c | 2 | ||||
-rw-r--r-- | fs/exec.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/fs/compat.c b/fs/compat.c index 075d0509970d..aae13d31612f 100644 --- a/fs/compat.c +++ b/fs/compat.c | |||
@@ -1239,7 +1239,7 @@ static int compat_count(compat_uptr_t __user *argv, int max) | |||
1239 | if (!p) | 1239 | if (!p) |
1240 | break; | 1240 | break; |
1241 | argv++; | 1241 | argv++; |
1242 | if(++i > max) | 1242 | if (i++ >= max) |
1243 | return -E2BIG; | 1243 | return -E2BIG; |
1244 | } | 1244 | } |
1245 | } | 1245 | } |
@@ -391,7 +391,7 @@ static int count(char __user * __user * argv, int max) | |||
391 | if (!p) | 391 | if (!p) |
392 | break; | 392 | break; |
393 | argv++; | 393 | argv++; |
394 | if(++i > max) | 394 | if (i++ >= max) |
395 | return -E2BIG; | 395 | return -E2BIG; |
396 | cond_resched(); | 396 | cond_resched(); |
397 | } | 397 | } |