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
02d3b72b
Unverified
Commit
02d3b72b
authored
Mar 09, 2020
by
Christian Brauner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
attach: use logging helpers when handling no new privileges
Signed-off-by:
Christian Brauner
<
christian.brauner@ubuntu.com
>
parent
cca66e06
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
8 deletions
+4
-8
attach.c
src/lxc/attach.c
+4
-8
No files found.
src/lxc/attach.c
View file @
02d3b72b
...
...
@@ -603,17 +603,13 @@ static bool no_new_privs(struct lxc_container *c, lxc_attach_options_t *options)
__do_free
char
*
val
=
NULL
;
/* Remove current setting. */
if
(
!
c
->
set_config_item
(
c
,
"lxc.no_new_privs"
,
""
))
{
INFO
(
"Failed to unset lxc.no_new_privs"
);
return
false
;
}
if
(
!
c
->
set_config_item
(
c
,
"lxc.no_new_privs"
,
""
))
return
log_info
(
false
,
"Failed to unset lxc.no_new_privs"
);
/* Retrieve currently active setting. */
val
=
c
->
get_running_config_item
(
c
,
"lxc.no_new_privs"
);
if
(
!
val
)
{
INFO
(
"Failed to retrieve lxc.no_new_privs"
);
return
false
;
}
if
(
!
val
)
return
log_info
(
false
,
"Failed to retrieve lxc.no_new_privs"
);
/* Set currently active setting. */
return
c
->
set_config_item
(
c
,
"lxc.no_new_privs"
,
val
);
...
...
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