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
679c5326
Commit
679c5326
authored
Dec 04, 2012
by
Pavel Emelyanov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ptrace: Remove dead code
Signed-off-by:
Pavel Emelyanov
<
xemul@parallels.com
>
parent
4cd99985
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
51 deletions
+0
-51
ptrace.h
include/ptrace.h
+0
-2
ptrace.c
ptrace.c
+0
-49
No files found.
include/ptrace.h
View file @
679c5326
...
@@ -39,7 +39,5 @@ extern int unseize_task(pid_t pid, int state);
...
@@ -39,7 +39,5 @@ extern int unseize_task(pid_t pid, int state);
extern
int
ptrace_peek_area
(
pid_t
pid
,
void
*
dst
,
void
*
addr
,
long
bytes
);
extern
int
ptrace_peek_area
(
pid_t
pid
,
void
*
dst
,
void
*
addr
,
long
bytes
);
extern
int
ptrace_poke_area
(
pid_t
pid
,
void
*
src
,
void
*
addr
,
long
bytes
);
extern
int
ptrace_poke_area
(
pid_t
pid
,
void
*
src
,
void
*
addr
,
long
bytes
);
extern
int
ptrace_swap_area
(
pid_t
pid
,
void
*
dst
,
void
*
src
,
long
bytes
);
extern
int
ptrace_swap_area
(
pid_t
pid
,
void
*
dst
,
void
*
src
,
long
bytes
);
extern
int
ptrace_show_area
(
pid_t
pid
,
void
*
addr
,
long
bytes
);
extern
int
ptrace_show_area_r
(
pid_t
pid
,
void
*
addr
,
long
bytes
);
#endif
/* SEIZE_H_ */
#endif
/* SEIZE_H_ */
ptrace.c
View file @
679c5326
...
@@ -140,55 +140,6 @@ err:
...
@@ -140,55 +140,6 @@ err:
return
-
1
;
return
-
1
;
}
}
int
ptrace_show_area_r
(
pid_t
pid
,
void
*
addr
,
long
bytes
)
{
unsigned
long
w
,
i
;
if
(
bytes
&
(
sizeof
(
long
)
-
1
))
return
-
1
;
for
(
w
=
0
;
w
<
bytes
/
sizeof
(
long
);
w
++
)
{
unsigned
long
*
a
=
addr
;
unsigned
long
v
;
v
=
ptrace
(
PTRACE_PEEKDATA
,
pid
,
a
+
w
,
NULL
);
if
(
v
==
-
1U
&&
errno
)
goto
err
;
else
{
unsigned
char
*
c
=
(
unsigned
char
*
)
&
v
;
for
(
i
=
sizeof
(
v
)
/
sizeof
(
*
c
);
i
>
0
;
i
--
)
pr_msg
(
"0x%02x "
,
c
[
i
-
1
]);
pr_msg
(
" "
);
}
}
pr_msg
(
"
\n
"
);
return
0
;
err:
return
-
2
;
}
int
ptrace_show_area
(
pid_t
pid
,
void
*
addr
,
long
bytes
)
{
unsigned
long
w
,
i
;
if
(
bytes
&
(
sizeof
(
long
)
-
1
))
return
-
1
;
pr_msg
(
"0x%016lx: "
,
(
unsigned
long
)
addr
);
for
(
w
=
0
;
w
<
bytes
/
sizeof
(
long
);
w
++
)
{
unsigned
long
*
a
=
addr
;
unsigned
long
v
;
v
=
ptrace
(
PTRACE_PEEKDATA
,
pid
,
a
+
w
,
NULL
);
if
(
v
==
-
1U
&&
errno
)
goto
err
;
else
{
unsigned
char
*
c
=
(
unsigned
char
*
)
&
v
;
for
(
i
=
0
;
i
<
sizeof
(
v
)
/
sizeof
(
*
c
);
i
++
)
pr_msg
(
"0x%02x "
,
c
[
i
]);
pr_msg
(
" "
);
}
}
pr_msg
(
"
\n
"
);
return
0
;
err:
return
-
2
;
}
int
ptrace_peek_area
(
pid_t
pid
,
void
*
dst
,
void
*
addr
,
long
bytes
)
int
ptrace_peek_area
(
pid_t
pid
,
void
*
dst
,
void
*
addr
,
long
bytes
)
{
{
unsigned
long
w
;
unsigned
long
w
;
...
...
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