Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 187162
b: refs/heads/master
c: 6e3e37a
h: refs/heads/master
v: v3
  • Loading branch information
André Goddard Rosa authored and Linus Torvalds committed Mar 12, 2010
1 parent c1901a2 commit 67e931e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5cacdb4add1b1e50fe75edc50ebbb7bddd9cf5e7
refs/heads/master: 6e3e37a5a7c91045497553bcbd6a5faea98b21b3
10 changes: 7 additions & 3 deletions trunk/include/linux/coredump.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ static inline int dump_write(struct file *file, const void *addr, int nr)

static inline int dump_seek(struct file *file, loff_t off)
{
int ret = 1;

if (file->f_op->llseek && file->f_op->llseek != no_llseek) {
if (file->f_op->llseek(file, off, SEEK_CUR) < 0)
return 0;
Expand All @@ -29,13 +31,15 @@ static inline int dump_seek(struct file *file, loff_t off)

if (n > PAGE_SIZE)
n = PAGE_SIZE;
if (!dump_write(file, buf, n))
return 0;
if (!dump_write(file, buf, n)) {
ret = 0;
break;
}
off -= n;
}
free_page((unsigned long)buf);
}
return 1;
return ret;
}

#endif /* _LINUX_COREDUMP_H */

0 comments on commit 67e931e

Please sign in to comment.