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
79e68309
Commit
79e68309
authored
Jan 19, 2010
by
Michel Normand
Committed by
Daniel Lezcano
Jan 20, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lxc: typo white space src/lxc/network.c
Signed-off-by:
Michel Normand
<
normand@fr.ibm.com
>
Signed-off-by:
Daniel Lezcano
<
dlezcano@fr.ibm.com
>
parent
84a24de2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
network.c
src/lxc/network.c
+12
-12
No files found.
src/lxc/network.c
View file @
79e68309
...
...
@@ -356,11 +356,11 @@ int lxc_veth_create(const char *name1, const char *name2)
link_req
=
(
struct
link_req
*
)
nlmsg
;
link_req
->
ifinfomsg
.
ifi_family
=
AF_UNSPEC
;
nlmsg
->
nlmsghdr
.
nlmsg_len
=
NLMSG_LENGTH
(
sizeof
(
struct
ifinfomsg
));
nlmsg
->
nlmsghdr
.
nlmsg_flags
=
nlmsg
->
nlmsghdr
.
nlmsg_flags
=
NLM_F_REQUEST
|
NLM_F_CREATE
|
NLM_F_EXCL
|
NLM_F_ACK
;
nlmsg
->
nlmsghdr
.
nlmsg_type
=
RTM_NEWLINK
;
nest1
=
nla_begin_nested
(
nlmsg
,
IFLA_LINKINFO
);
nest1
=
nla_begin_nested
(
nlmsg
,
IFLA_LINKINFO
);
if
(
!
nest1
)
goto
out
;
...
...
@@ -439,7 +439,7 @@ int lxc_vlan_create(const char *master, const char *name, ushort vlanid)
NLM_F_REQUEST
|
NLM_F_CREATE
|
NLM_F_EXCL
|
NLM_F_ACK
;
nlmsg
->
nlmsghdr
.
nlmsg_type
=
RTM_NEWLINK
;
nest
=
nla_begin_nested
(
nlmsg
,
IFLA_LINKINFO
);
nest
=
nla_begin_nested
(
nlmsg
,
IFLA_LINKINFO
);
if
(
!
nest
)
goto
err1
;
...
...
@@ -514,7 +514,7 @@ int lxc_macvlan_create(const char *master, const char *name, int mode)
NLM_F_REQUEST
|
NLM_F_CREATE
|
NLM_F_EXCL
|
NLM_F_ACK
;
nlmsg
->
nlmsghdr
.
nlmsg_type
=
RTM_NEWLINK
;
nest
=
nla_begin_nested
(
nlmsg
,
IFLA_LINKINFO
);
nest
=
nla_begin_nested
(
nlmsg
,
IFLA_LINKINFO
);
if
(
!
nest
)
goto
out
;
...
...
@@ -573,7 +573,7 @@ static int ip_forward_set(const char *ifname, int family, int flag)
if
(
family
!=
AF_INET
&&
family
!=
AF_INET6
)
return
-
1
;
snprintf
(
path
,
MAXPATHLEN
,
"/proc/sys/net/%s/conf/%s/forwarding"
,
snprintf
(
path
,
MAXPATHLEN
,
"/proc/sys/net/%s/conf/%s/forwarding"
,
family
==
AF_INET
?
"ipv4"
:
"ipv6"
,
ifname
);
return
proc_sys_net_write
(
path
,
flag
?
"1"
:
"0"
);
...
...
@@ -596,8 +596,8 @@ static int neigh_proxy_set(const char *ifname, int family, int flag)
if
(
family
!=
AF_INET
&&
family
!=
AF_INET6
)
return
-
1
;
sprintf
(
path
,
"/proc/sys/net/%s/conf/%s/%s"
,
family
==
AF_INET
?
"ipv4"
:
"ipv6"
,
ifname
,
sprintf
(
path
,
"/proc/sys/net/%s/conf/%s/%s"
,
family
==
AF_INET
?
"ipv4"
:
"ipv6"
,
ifname
,
family
==
AF_INET
?
"proxy_arp"
:
"proxy_ndp"
);
return
proc_sys_net_write
(
path
,
flag
?
"1"
:
"0"
);
...
...
@@ -698,10 +698,10 @@ int lxc_ip_addr_add(int family, int ifindex, void *addr, int prefix)
if
(
nla_put_buffer
(
nlmsg
,
IFA_ADDRESS
,
addr
,
addrlen
))
goto
out
;
/*
if (in_bcast.s_addr != INADDR_ANY) */
/*
if (nla_put_buffer(nlmsg, IFA_BROADCAST, &in_bcast, */
/*
sizeof(in_bcast))) */
/*
goto out; */
/* if (in_bcast.s_addr != INADDR_ANY) */
/* if (nla_put_buffer(nlmsg, IFA_BROADCAST, &in_bcast, */
/* sizeof(in_bcast))) */
/* goto out; */
if
(
netlink_transaction
(
&
nlh
,
nlmsg
,
answer
))
goto
out
;
...
...
@@ -714,7 +714,7 @@ out:
return
err
;
}
static
int
bridge_add_del_interface
(
const
char
*
bridge
,
static
int
bridge_add_del_interface
(
const
char
*
bridge
,
const
char
*
ifname
,
int
detach
)
{
int
fd
,
index
,
err
;
...
...
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