Message ID | 1450287568-19808-69-git-send-email-kamal@canonical.com |
---|---|
State | New |
Headers | show |
diff --git a/fs/splice.c b/fs/splice.c index 75c6058..d934f8e4 100644 --- a/fs/splice.c +++ b/fs/splice.c @@ -806,6 +806,13 @@ static int splice_from_pipe_feed(struct pipe_inode_info *pipe, struct splice_des */ static int splice_from_pipe_next(struct pipe_inode_info *pipe, struct splice_desc *sd) { + /* + * Check for signal early to make process killable when there are + * always buffers available + */ + if (signal_pending(current)) + return -ERESTARTSYS; + while (!pipe->nrbufs) { if (!pipe->writers) return 0;