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
81023568
Unverified
Commit
81023568
authored
Dec 09, 2020
by
Christian Brauner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
confile: cleanup get_config_net_veth_ipv6_route()
Signed-off-by:
Christian Brauner
<
christian.brauner@ubuntu.com
>
parent
492955be
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
confile.c
src/lxc/confile.c
+4
-3
No files found.
src/lxc/confile.c
View file @
81023568
...
...
@@ -5694,7 +5694,7 @@ static int get_config_net_ipv6_address(const char *key, char *retv, int inlen,
}
static
int
get_config_net_veth_ipv6_route
(
const
char
*
key
,
char
*
retv
,
int
inlen
,
struct
lxc_conf
*
c
,
void
*
data
)
struct
lxc_conf
*
c
,
void
*
data
)
{
int
len
;
size_t
listlen
;
...
...
@@ -5709,7 +5709,7 @@ static int get_config_net_veth_ipv6_route(const char *key, char *retv, int inlen
memset
(
retv
,
0
,
inlen
);
if
(
!
netdev
)
return
ret_
set_errno
(
-
1
,
EINVAL
);
return
ret_
errno
(
EINVAL
);
if
(
netdev
->
type
!=
LXC_NET_VETH
)
return
0
;
...
...
@@ -5718,7 +5718,8 @@ static int get_config_net_veth_ipv6_route(const char *key, char *retv, int inlen
lxc_list_for_each
(
it
,
&
netdev
->
priv
.
veth_attr
.
ipv6_routes
)
{
struct
lxc_inet6dev
*
i
=
it
->
elem
;
inet_ntop
(
AF_INET6
,
&
i
->
addr
,
buf
,
sizeof
(
buf
));
if
(
!
inet_ntop
(
AF_INET6
,
&
i
->
addr
,
buf
,
sizeof
(
buf
)))
return
-
errno
;
strprint
(
retv
,
inlen
,
"%s/%u%s"
,
buf
,
i
->
prefix
,
(
listlen
--
>
1
)
?
"
\n
"
:
""
);
}
...
...
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