Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 54567
b: refs/heads/master
c: af7c693
h: refs/heads/master
i:
  54565: 375ad9e
  54563: e52e7b6
  54559: cc9afaf
v: v3
  • Loading branch information
Guy Streeter authored and Linus Torvalds committed May 8, 2007
1 parent 0e8f908 commit e4778cf
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ee527cd3a20c2aeaac17d939e5d011f7a76d69f5
refs/heads/master: af7c693f146069a1f44739acef9abf1bc27f7247
4 changes: 4 additions & 0 deletions trunk/ipc/compat.c
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,8 @@ static inline int put_compat_shminfo64(struct shminfo64 *smi,

if (!access_ok(VERIFY_WRITE, up64, sizeof(*up64)))
return -EFAULT;
if (smi->shmmax > INT_MAX)
smi->shmmax = INT_MAX;
err = __put_user(smi->shmmax, &up64->shmmax);
err |= __put_user(smi->shmmin, &up64->shmmin);
err |= __put_user(smi->shmmni, &up64->shmmni);
Expand All @@ -557,6 +559,8 @@ static inline int put_compat_shminfo(struct shminfo64 *smi,

if (!access_ok(VERIFY_WRITE, up, sizeof(*up)))
return -EFAULT;
if (smi->shmmax > INT_MAX)
smi->shmmax = INT_MAX;
err = __put_user(smi->shmmax, &up->shmmax);
err |= __put_user(smi->shmmin, &up->shmmin);
err |= __put_user(smi->shmmni, &up->shmmni);
Expand Down

0 comments on commit e4778cf

Please sign in to comment.