Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
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
Chen Yisong
lxc
Commits
431c1c05
Unverified
Commit
431c1c05
authored
Apr 15, 2021
by
Christian Brauner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
process_utils: free stack after return
Fixes: #3789 Signed-off-by:
Christian Brauner
<
christian.brauner@ubuntu.com
>
parent
cdfa8f13
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
process_utils.c
src/lxc/process_utils.c
+3
-5
No files found.
src/lxc/process_utils.c
View file @
431c1c05
...
...
@@ -146,14 +146,12 @@ int lxc_raw_pidfd_send_signal(int pidfd, int sig, siginfo_t *info,
#define __LXC_STACK_SIZE (8 * 1024 * 1024)
pid_t
lxc_clone
(
int
(
*
fn
)(
void
*
),
void
*
arg
,
int
flags
,
int
*
pidfd
)
{
__do_free
void
*
stack
=
NULL
;
pid_t
ret
;
void
*
stack
;
stack
=
malloc
(
__LXC_STACK_SIZE
);
if
(
!
stack
)
{
SYSERROR
(
"Failed to allocate clone stack"
);
return
-
ENOMEM
;
}
if
(
!
stack
)
return
syserror_set
(
-
ENOMEM
,
"Failed to allocate clone stack"
);
#ifdef __ia64__
ret
=
__clone2
(
fn
,
stack
,
__LXC_STACK_SIZE
,
flags
|
SIGCHLD
,
arg
,
pidfd
);
...
...
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