Commit Graph
7 Commits
Author SHA1 Message Date
Davide Pesavento e4631003a9 face: silence silly warning thrown by clang.
Clang 3.3 complains about a "missing field initializer" for struct ifreq.
However, according to the standard, if there are fewer initializers in a
brace-enclosed list than there are elements or members of an aggregate,
the remainder of the aggregate shall be initialized implicitly as if they
were declared static, i.e. with zero or default-constructed value.

Therefore using "= {0}" is correct (and common practice in C). Emitting
a warning doesn't make sense. As a matter of fact recent GCC releases
disabled it.

Luckily this is C++ and we can simply use the "empty braces" initializer
(which wouldn't be valid C99 syntax) to silence the compiler.

Change-Id: Ibee8d17cc9b5d0eaa5270c52f3596b7994b5e911
2014-03-21 15:44:42 -07:00
Davide Pesavento b60cc1298d face: use NetworkInterfaceInfo directly in EthernetFace.
Finally getting rid of EthernetFactory::findAllInterfaces()
and EthernetFace::getInterfaceAddress().

Change-Id: I94fe2016cc98778af3115569b1d21d5c48425d9c
2014-03-20 21:07:22 -07:00
Davide Pesavento 9eaeac7716 face: enable promiscuous mode in Ethernet face.
This is a temporary hack to be able to receive NDN packets sent to
an Ethernet multicast address different from the broadcast address.
It'll be removed when task #1278 is properly implemented.

Change-Id: I87380637ef2993cf28889ab69f13dc8b75b9644e
2014-03-15 10:18:33 +01:00
Alexander Afanasyev 7e698e6aac face: Incrementing Face counters
Change-Id: Ia1d7917bb52cf01ab2ff304638bc9f6cbdb2626f
Refs: #1178
2014-03-08 20:27:43 +00:00
Alexander Afanasyev a39b90b2aa face: Implementing Face::getUri() method
Change-Id: I9a9f774b95784e5b7ec75472f1cc6cf64c4e5d7b
Refs: #1319
2014-03-06 09:25:06 +00:00
Davide Pesavento 0ff10db95a face: remove awkward Face::setLocal, use a constructor argument instead.
Change-Id: Ic366ecdc83c5771138ff584ffb944a4e17300eb1
2014-02-28 08:45:14 -08:00
Davide Pesavento 44deacc811 face: Ethernet{Face,ChannelFactory} implementation.
refs: #1191

Change-Id: I08b7ebfdc5d70fb494b1f23bd7b1a77cf18653a1
2014-02-27 18:18:34 +01:00