mirror of
https://github.com/checkpoint-restore/criu
synced 2025-09-02 07:15:31 +00:00
ghost: Fixup mkreg_ghost prototype
We don't need gf there, but will need more than just mode. Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com> Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
committed by
Andrei Vagin
parent
1ddcd443ba
commit
c3cff79cd6
@@ -142,11 +142,11 @@ static int trim_last_parent(char *path)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int mkreg_ghost(char *path, u32 mode, struct ghost_file *gf, struct cr_img *img)
|
static int mkreg_ghost(char *path, GhostFileEntry *gfe, struct cr_img *img)
|
||||||
{
|
{
|
||||||
int gfd, ret;
|
int gfd, ret;
|
||||||
|
|
||||||
gfd = open(path, O_WRONLY | O_CREAT | O_EXCL, mode);
|
gfd = open(path, O_WRONLY | O_CREAT | O_EXCL, gfe->mode);
|
||||||
if (gfd < 0)
|
if (gfd < 0)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
@@ -218,7 +218,7 @@ again:
|
|||||||
if ((ret = mkdirpat(AT_FDCWD, path, gfe->mode)) < 0)
|
if ((ret = mkdirpat(AT_FDCWD, path, gfe->mode)) < 0)
|
||||||
msg = "Can't make ghost dir";
|
msg = "Can't make ghost dir";
|
||||||
} else {
|
} else {
|
||||||
if ((ret = mkreg_ghost(path, gfe->mode, gf, img)) < 0)
|
if ((ret = mkreg_ghost(path, gfe, img)) < 0)
|
||||||
msg = "Can't create ghost regfile";
|
msg = "Can't create ghost regfile";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user