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
46083e9e
Commit
46083e9e
authored
Nov 22, 2011
by
Cyrill Gorcunov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
restore: Don't forget to skip data on attached pipes
Signed-off-by:
Cyrill Gorcunov
<
gorcunov@gmail.com
>
parent
0cd579ab
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
cr-restore.c
cr-restore.c
+4
-2
No files found.
cr-restore.c
View file @
46083e9e
...
...
@@ -952,7 +952,7 @@ static int create_pipe(int pid, struct pipe_entry *e, struct pipe_info *pi, int
return
0
;
}
static
int
attach_pipe
(
int
pid
,
struct
pipe_entry
*
e
,
struct
pipe_info
*
pi
)
static
int
attach_pipe
(
int
pid
,
struct
pipe_entry
*
e
,
struct
pipe_info
*
pi
,
int
pipes_fd
)
{
char
path
[
128
];
int
tmp
,
fd
;
...
...
@@ -989,6 +989,8 @@ static int attach_pipe(int pid, struct pipe_entry *e, struct pipe_info *pi)
return
1
;
pi
->
users
--
;
lseek
(
pipes_fd
,
e
->
bytes
,
SEEK_CUR
);
return
0
;
}
...
...
@@ -1025,7 +1027,7 @@ static int open_pipe(int pid, struct pipe_entry *e, int *pipes_fd)
if
(
pi
->
pid
==
pid
&&
!
(
pi
->
status
&
PIPE_CREATED
))
return
create_pipe
(
pid
,
e
,
pi
,
*
pipes_fd
);
else
return
attach_pipe
(
pid
,
e
,
pi
);
return
attach_pipe
(
pid
,
e
,
pi
,
*
pipes_fd
);
}
static
int
prepare_pipes
(
int
pid
)
...
...
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