2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-30 22:05:36 +00:00

restore: fix length of spliced data

Signed-off-by: Andrey Vagin <avagin@openvz.org>
Acked-by: Pavel Emelyanov <xemul@parallels.com>
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
This commit is contained in:
Andrey Vagin
2012-02-01 16:02:02 +03:00
committed by Cyrill Gorcunov
parent 229defc928
commit 3f614e4498

View File

@@ -778,7 +778,7 @@ static int restore_pipe_data(struct pipe_entry *e, int wfd, int pipes_fd)
pr_info("\t%x: Splicing data to %d\n", e->pipeid, wfd);
while (size != e->bytes) {
ret = splice(pipes_fd, NULL, wfd, NULL, e->bytes, 0);
ret = splice(pipes_fd, NULL, wfd, NULL, e->bytes - size, 0);
if (ret < 0) {
pr_perror("\t%x: Error splicing data", e->pipeid);
return -1;