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
952975c9
Commit
952975c9
authored
May 16, 2010
by
dermiste
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
implementing kernel_interface_wireless in kernel_socket.c
parent
7e9f1b1b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
1 deletion
+14
-1
kernel_socket.c
kernel_socket.c
+14
-1
No files found.
kernel_socket.c
View file @
952975c9
...
...
@@ -285,7 +285,20 @@ kernel_interface_mtu(const char *ifname, int ifindex)
int
kernel_interface_wireless
(
const
char
*
ifname
,
int
ifindex
)
{
return
-
1
;
struct
ifmediareq
ifmr
;
int
s
,
rc
;
s
=
socket
(
PF_INET6
,
SOCK_DGRAM
,
0
);
memset
(
&
ifmr
,
0
,
sizeof
(
ifmr
));
strncpy
(
ifmr
.
ifm_name
,
ifname
,
sizeof
(
ifmr
.
ifm_name
));
rc
=
ioctl
(
s
,
SIOCGIFMEDIA
,
(
caddr_t
)
&
ifmr
);
close
(
s
);
if
(
rc
<
0
)
return
rc
;
if
((
ifmr
.
ifm_active
&
IFM_NMASK
)
==
IFM_IEEE80211
)
return
1
;
else
return
0
;
}
int
...
...
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