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
6d25a524
Unverified
Commit
6d25a524
authored
Feb 15, 2021
by
Christian Brauner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
conf: don't pass conf separately to lxc_mount_auto_mounts()
Signed-off-by:
Christian Brauner
<
christian.brauner@ubuntu.com
>
parent
c988c8b1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
conf.c
src/lxc/conf.c
+4
-3
No files found.
src/lxc/conf.c
View file @
6d25a524
...
...
@@ -564,7 +564,7 @@ static int add_shmount_to_list(struct lxc_conf *conf)
return
add_elem_to_mount_list
(
new_mount
,
conf
);
}
static
int
lxc_mount_auto_mounts
(
struct
lxc_
conf
*
conf
,
int
flags
,
struct
lxc_handler
*
handler
)
static
int
lxc_mount_auto_mounts
(
struct
lxc_
handler
*
handler
,
int
flags
)
{
int
i
,
ret
;
static
struct
{
...
...
@@ -608,6 +608,7 @@ static int lxc_mount_auto_mounts(struct lxc_conf *conf, int flags, struct lxc_ha
{
LXC_AUTO_SYS_MASK
,
LXC_AUTO_SYS_MIXED
,
NULL
,
"%r/sys/devices/virtual/net"
,
NULL
,
MS_REMOUNT
|
MS_BIND
|
MS_NOSUID
|
MS_NODEV
|
MS_NOEXEC
,
NULL
,
false
},
{
0
,
0
,
NULL
,
NULL
,
NULL
,
0
,
NULL
,
false
}
};
struct
lxc_conf
*
conf
=
handler
->
conf
;
struct
lxc_rootfs
*
rootfs
=
&
conf
->
rootfs
;
bool
has_cap_net_admin
;
...
...
@@ -3432,7 +3433,7 @@ int lxc_setup(struct lxc_handler *handler)
/* Do automatic mounts (mainly /proc and /sys), but exclude those that
* need to wait until other stuff has finished.
*/
ret
=
lxc_mount_auto_mounts
(
lxc_conf
,
lxc_conf
->
auto_mounts
&
~
LXC_AUTO_CGROUP_MASK
,
handler
);
ret
=
lxc_mount_auto_mounts
(
handler
,
lxc_conf
->
auto_mounts
&
~
LXC_AUTO_CGROUP_MASK
);
if
(
ret
<
0
)
return
log_error
(
-
1
,
"Failed to setup first automatic mounts"
);
...
...
@@ -3473,7 +3474,7 @@ int lxc_setup(struct lxc_handler *handler)
* mounted. It is guaranteed to be mounted now either through
* automatically or via fstab entries.
*/
ret
=
lxc_mount_auto_mounts
(
lxc_conf
,
lxc_conf
->
auto_mounts
&
LXC_AUTO_CGROUP_MASK
,
handler
);
ret
=
lxc_mount_auto_mounts
(
handler
,
lxc_conf
->
auto_mounts
&
LXC_AUTO_CGROUP_MASK
);
if
(
ret
<
0
)
return
log_error
(
-
1
,
"Failed to setup remaining automatic mounts"
);
...
...
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