2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-31 06:15:24 +00:00

dump: use fd_params->type for cwd and exe magic

This is a cleanup patch. Use file entry type variable for special files
instead of file entry addr variable.

Signed-off-by: Stanislav Kinsbursky <skinsbursky@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
Kinsbursky Stanislav
2012-03-06 15:52:00 +04:00
committed by Pavel Emelyanov
parent fede33e047
commit c1999ec58e
4 changed files with 14 additions and 15 deletions

View File

@@ -29,12 +29,12 @@
#define PIPEFS_MAGIC 0x50495045
#define FDINFO_FD 1
#define FDINFO_REG 1
#define FDINFO_MAP 2
/* Specials */
#define FDINFO_CWD (-1ULL)
#define FDINFO_EXE (-2ULL)
#define FDINFO_CWD 3
#define FDINFO_EXE 4
#define PAGE_IMAGE_SIZE 4096
#define PAGE_RSS 1
@@ -51,9 +51,9 @@ struct fdinfo_entry {
} __packed;
#define fd_is_special(fe) \
(((fe)->type != FDINFO_FD) || \
((fe)->addr == FDINFO_CWD) || \
((fe)->addr == FDINFO_EXE))
(((fe)->type == FDINFO_MAP) || \
((fe)->type == FDINFO_CWD) || \
((fe)->type == FDINFO_EXE))
struct shmem_entry {
u64 start;