Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
criu
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhul
criu
Commits
0259dd01
Commit
0259dd01
authored
Oct 24, 2011
by
Cyrill Gorcunov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
restore: Use open_fmt_ro helper
Signed-off-by:
Cyrill Gorcunov
<
gorcunov@gmail.com
>
parent
ea0f8eac
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
cr-restore.c
cr-restore.c
+7
-7
No files found.
cr-restore.c
View file @
0259dd01
...
...
@@ -292,7 +292,7 @@ static int prepare_shmem_pid(int pid)
int
sh_fd
;
u32
type
=
0
;
sh_fd
=
open_fmt
(
"shmem-%d.img"
,
O_RDONLY
,
pid
);
sh_fd
=
open_fmt
_ro
(
"shmem-%d.img"
,
pid
);
if
(
sh_fd
<
0
)
{
perror
(
"Can't open shmem info"
);
return
1
;
...
...
@@ -330,7 +330,7 @@ static int prepare_pipes_pid(int pid)
int
p_fd
;
u32
type
=
0
;
p_fd
=
open_fmt
(
"pipes-%d.img"
,
O_RDONLY
,
pid
);
p_fd
=
open_fmt
_ro
(
"pipes-%d.img"
,
pid
);
if
(
p_fd
<
0
)
{
perror
(
"Can't open pipes image"
);
return
1
;
...
...
@@ -511,7 +511,7 @@ static int prepare_fds(int pid)
pr_info
(
"%d: Opening files img
\n
"
,
pid
);
fdinfo_fd
=
open_fmt
(
"fdinfo-%d.img"
,
O_RDONLY
,
pid
);
fdinfo_fd
=
open_fmt
_ro
(
"fdinfo-%d.img"
,
pid
);
if
(
fdinfo_fd
<
0
)
{
pr_perror
(
"Can't open %d fdinfo"
,
pid
);
return
1
;
...
...
@@ -590,7 +590,7 @@ static int prepare_shmem(int pid)
int
sh_fd
;
u32
type
=
0
;
sh_fd
=
open_fmt
(
"shmem-%d.img"
,
O_RDONLY
,
pid
);
sh_fd
=
open_fmt
_ro
(
"shmem-%d.img"
,
pid
);
if
(
sh_fd
<
0
)
{
perror
(
"Can't open shmem info"
);
return
1
;
...
...
@@ -744,7 +744,7 @@ static int fixup_pages_data(int pid, int fd)
pr_info
(
"%d: Reading shmem pages img
\n
"
,
pid
);
shfd
=
open_fmt
(
"pages-shmem-%d.img"
,
O_RDONLY
,
pid
);
shfd
=
open_fmt
_ro
(
"pages-shmem-%d.img"
,
pid
);
if
(
shfd
<
0
)
{
pr_perror
(
"Can't open %d shmem image %s"
,
pid
);
return
1
;
...
...
@@ -826,7 +826,7 @@ static int prepare_and_execute_image(int pid)
int
fd
,
fd_new
;
struct
stat
buf
;
fd
=
open_fmt
(
"core-%d.img"
,
O_RDONLY
,
pid
);
fd
=
open_fmt
_ro
(
"core-%d.img"
,
pid
);
if
(
fd
<
0
)
{
perror
(
"Can't open exec image"
);
return
1
;
...
...
@@ -1037,7 +1037,7 @@ static int prepare_pipes(int pid)
pr_info
(
"%d: Opening pipes
\n
"
,
pid
);
pipes_fd
=
open_fmt
(
"pipes-%d.img"
,
O_RDONLY
,
pid
);
pipes_fd
=
open_fmt
_ro
(
"pipes-%d.img"
,
pid
);
if
(
pipes_fd
<
0
)
{
perror
(
"Can't open pipes img"
);
return
1
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment