2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-09-02 15:25:21 +00:00

files: Compact the code by removing per-file dump helpers

Since *all* of them just call do_dump_gen_file with proper ops,
just call one directly. Compacts the code.

Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
Pavel Emelyanov
2013-06-14 00:11:08 +04:00
parent 42f77676b6
commit d020ebb36d
26 changed files with 65 additions and 126 deletions

View File

@@ -251,16 +251,11 @@ err:
return -1;
}
static const struct fdtype_ops unix_dump_ops = {
const struct fdtype_ops unix_dump_ops = {
.type = FD_TYPES__UNIXSK,
.dump = dump_one_unix_fd,
};
int dump_one_unix(struct fd_parms *p, int lfd, const int fdinfo)
{
return do_dump_gen_file(p, lfd, &unix_dump_ops, fdinfo);
}
static int unix_collect_one(const struct unix_diag_msg *m,
struct rtattr **tb)
{