Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
babeld
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
babeld
Commits
72480049
Commit
72480049
authored
May 19, 2008
by
Juliusz Chroboczek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Flush parse_ifflags.
This saves 512 bytes of BSS.
parent
d1c82a6e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
2 additions
and
19 deletions
+2
-19
kernel_netlink.c
kernel_netlink.c
+2
-2
util.c
util.c
+0
-16
util.h
util.h
+0
-1
No files found.
kernel_netlink.c
View file @
72480049
...
...
@@ -1044,8 +1044,8 @@ filter_link(struct nlmsghdr *nh, void *data)
ifname
=
parse_ifname_rta
(
info
,
len
);
if
(
ifname
==
NULL
)
return
0
;
kdebugf
(
"filter_interfaces: link change on if %s(%d):
%s
\n
"
,
ifname
,
ifindex
,
parse_ifflags
(
ifflags
)
);
kdebugf
(
"filter_interfaces: link change on if %s(%d):
0x%x
\n
"
,
ifname
,
ifindex
,
(
unsigned
)
ifflags
);
FOR_ALL_NETS
(
net
)
{
if
(
strcmp
(
net
->
ifname
,
ifname
)
==
0
)
return
1
;
...
...
util.c
View file @
72480049
...
...
@@ -387,22 +387,6 @@ v4tov6(unsigned char *dst, const unsigned char *src)
memcpy
(
dst
+
12
,
src
,
4
);
}
char
*
parse_ifflags
(
unsigned
int
flags
)
{
static
char
buf
[
512
];
buf
[
0
]
=
'\0'
;
if
(
flags
&
IFF_UP
)
strcat
(
buf
,
"UP "
);
if
(
flags
&
IFF_BROADCAST
)
strcat
(
buf
,
"BROADCAST "
);
if
(
flags
&
IFF_RUNNING
)
strcat
(
buf
,
"RUNNING "
);
if
(
flags
&
IFF_MULTICAST
)
strcat
(
buf
,
"MULTICAST "
);
return
buf
;
}
int
daemonise
()
{
...
...
util.h
View file @
72480049
...
...
@@ -54,7 +54,6 @@ int wait_for_fd(int direction, int fd, int msecs);
int
martian_prefix
(
const
unsigned
char
*
prefix
,
int
plen
)
ATTRIBUTE
((
pure
));
int
v4mapped
(
const
unsigned
char
*
address
)
ATTRIBUTE
((
pure
));
void
v4tov6
(
unsigned
char
*
dst
,
const
unsigned
char
*
src
);
char
*
parse_ifflags
(
unsigned
int
flags
);
int
daemonise
(
void
);
/* If debugging is disabled, we want to avoid calling format_address
...
...
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