mirror of
https://github.com/checkpoint-restore/criu
synced 2025-08-31 06:15:24 +00:00
pb: Rewrite object reading to use pb-descs
The pb_read thing is no longer a macros. This will allow to factor out objects collecting on restore. Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
4
files.c
4
files.c
@@ -215,7 +215,7 @@ int prepare_fd_pid(int pid, struct rst_info *rst_info)
|
||||
while (1) {
|
||||
FdinfoEntry *e;
|
||||
|
||||
ret = pb_read_eof(fdinfo_fd, &e, fdinfo_entry);
|
||||
ret = pb_read_one_eof(fdinfo_fd, &e, PB_FDINFO);
|
||||
if (ret <= 0)
|
||||
break;
|
||||
|
||||
@@ -505,7 +505,7 @@ int prepare_fs(int pid)
|
||||
if (ifd < 0)
|
||||
return -1;
|
||||
|
||||
if (pb_read(ifd, &fe, fs_entry) < 0)
|
||||
if (pb_read_one(ifd, &fe, PB_FS) < 0)
|
||||
return -1;
|
||||
|
||||
cwd = open_reg_by_id(fe->cwd_id);
|
||||
|
Reference in New Issue
Block a user