]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
criu: s/read()/lxc_read_nointr()/g
authorChristian Brauner <christian.brauner@ubuntu.com>
Sun, 29 Jul 2018 21:46:54 +0000 (23:46 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Mon, 10 Dec 2018 15:03:53 +0000 (16:03 +0100)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/criu.c

index 0c29a1374bd27294ed31b06eedf28a0713bcbe68..ca1054f30f4819fb36aa8fe2842cc9c657eb1be8 100644 (file)
@@ -983,7 +983,7 @@ static void do_restore(struct lxc_container *c, int status_pipe, struct migrate_
                        if (WEXITSTATUS(status)) {
                                int n;
 
-                               n = read(pipes[0], buf, sizeof(buf));
+                               n = lxc_read_nointr(pipes[0], buf, sizeof(buf));
                                if (n < 0) {
                                        SYSERROR("failed reading from criu stderr");
                                        goto out_fini_handler;
@@ -1206,7 +1206,7 @@ static bool do_dump(struct lxc_container *c, char *mode, struct migrate_opts *op
                        return false;
                }
 
-               n = read(criuout[0], buf, sizeof(buf));
+               n = lxc_read_nointr(criuout[0], buf, sizeof(buf));
                close(criuout[0]);
                if (n < 0) {
                        SYSERROR("read");
@@ -1309,7 +1309,7 @@ bool __criu_restore(struct lxc_container *c, struct migrate_opts *opts)
        close(pipefd[1]);
        free(criu_version);
 
-       nread = read(pipefd[0], &status, sizeof(status));
+       nread = lxc_read_nointr(pipefd[0], &status, sizeof(status));
        close(pipefd[0]);
        if (sizeof(status) != nread) {
                ERROR("reading status from pipe failed");