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
a9c51a82
Unverified
Commit
a9c51a82
authored
Dec 05, 2017
by
Stéphane Graber
Committed by
GitHub
Dec 05, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2004 from brauner/2017-12-06/fix_log_env_variable
start: set loglevel correctly
parents
a144d288
4a03ded4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
start.c
src/lxc/start.c
+4
-2
No files found.
src/lxc/start.c
View file @
a9c51a82
...
...
@@ -572,6 +572,7 @@ on_error:
int
lxc_init
(
const
char
*
name
,
struct
lxc_handler
*
handler
)
{
const
char
*
loglevel
;
struct
lxc_conf
*
conf
=
handler
->
conf
;
lsm_init
();
...
...
@@ -612,8 +613,9 @@ int lxc_init(const char *name, struct lxc_handler *handler)
if
(
setenv
(
"LXC_CGNS_AWARE"
,
"1"
,
1
))
SYSERROR
(
"Failed to set environment variable LXC_CGNS_AWARE=1."
);
if
(
setenv
(
"LXC_LOG_LEVEL"
,
lxc_log_priority_to_string
(
handler
->
conf
->
loglevel
),
1
))
SYSERROR
(
"Failed to set environment variable LXC_CGNS_AWARE=1."
);
loglevel
=
lxc_log_priority_to_string
(
lxc_log_get_level
());
if
(
setenv
(
"LXC_LOG_LEVEL"
,
loglevel
,
1
))
SYSERROR
(
"Failed to set environment variable LXC_LOG_LEVEL=%s"
,
loglevel
);
/* End of environment variable setup for hooks. */
TRACE
(
"set environment variables"
);
...
...
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