Mark Salyzyn
66ce3e08c5
system/core Replace cutils/log.h with android/log.h
...
Should use android/log.h instead of cutils/log.h as a good example
to all others. Adjust header order to comply with Android Coding
standards.
Test: Compile
Bug: 26552300
Bug: 31289077
Change-Id: I2c9cbbbd64d8dccf2d44356361d9742e4a9b9031
2016-09-30 12:47:05 -07:00
Erik Kline
d72ba4489c
Remove deprecated libnetutils DHCPv4 code
...
Change-Id: I9777730fee0f5c1877b246aa65b03e82d6f475a5
2016-09-10 09:14:51 +09:00
Elliott Hughes
9110eaab41
resolve merge conflicts of 847d963
to nyc-dev-plus-aosp
...
Change-Id: Ib97f56112bff71e2997116f969fd6d3e30e72f26
2016-05-18 21:26:35 -07:00
Elliott Hughes
847d963598
Remove a dead header (<netutils/dhcp.h>).
...
9c07eb9dd8
removed the implementation, but
missed the header file.
Bug: http://b/27192644
Change-Id: I809a3eb0081b05783b70dbca0274cdde6b1b31a6
2016-05-18 14:22:15 -07:00
Erik Kline
91bc2c9084
Merge "Set IFA_BROADCAST during IPv4 RTM_NEWADDRs" am: d709914
...
am: 012d35b
* commit '012d35b7f046f42d97dadd831c8201ecda2daa55':
Set IFA_BROADCAST during IPv4 RTM_NEWADDRs
Change-Id: Ib4ac0486a06551dce8d79fb1e738e9c567328610
2016-03-31 07:10:47 +00:00
Erik Kline
e3a769529b
Set IFA_BROADCAST during IPv4 RTM_NEWADDRs
...
Bug: 27194345
Bug: 27732412
Bug: 27786864
Change-Id: I5a5b41422bbaab4582c268c213b788f61cb0e169
(cherry picked from commit 06cb8e9203
)
2016-03-31 16:00:40 +09:00
Erik Kline
06cb8e9203
Set IFA_BROADCAST during IPv4 RTM_NEWADDRs
...
Bug: 27194345
Bug: 27732412
Bug: 27786864
Change-Id: I5a5b41422bbaab4582c268c213b788f61cb0e169
2016-03-30 20:06:36 +09:00
Lorenzo Colitti
5e953a2909
Merge "Delete dhcpcd code in system/core, since dhcpcd is no more." into nyc-dev
...
am: b046e74bef
* commit 'b046e74beff221d96189c4142f42f18730565921':
Delete dhcpcd code in system/core, since dhcpcd is no more.
2016-02-25 07:57:34 +00:00
Lorenzo Colitti
9c07eb9dd8
Delete dhcpcd code in system/core, since dhcpcd is no more.
...
Bug: 27192644
Change-Id: I44c2ded2da69395f12a8850b2677322b11c2cb91
2016-02-25 16:04:43 +09:00
Elliott Hughes
5ce57a6717
Merge "Move libnetutils headers into libnetutils."
...
am: d61ad3c44e
* commit 'd61ad3c44eba0d9b9248005a9068e6b477c06c32':
Move libnetutils headers into libnetutils.
2016-02-16 22:11:31 +00:00
Elliott Hughes
8501751bdf
Move libnetutils headers into libnetutils.
...
Change-Id: I8e51b369b7617e780db78c2f77c8e28d0fb93445
2016-02-12 18:10:06 -08:00
Elliott Hughes
34965eb118
Merge "libnetutils: Check socket() return value" am: e4b332c7e4
...
am: be6d330c18
* commit 'be6d330c18f861fe10c0b238f74cecb2c9783205':
libnetutils: Check socket() return value
2016-01-12 04:53:01 +00:00
Bjorn Andersson
292997420c
libnetutils: Check socket() return value
...
Add a check for socket() errors and make sure to preserve errno over the
subsequent close() calls.
Change-Id: If52d76cd3cb45044eaaf7fea9bfd4471dc66a078
2015-12-29 11:17:05 -08:00
Dmitry Shmidt
cebcd450c6
libnetutils: Add synchronization per socket full operation
...
Take and release mutex between ifc_init() and ifc_close()
calls to prevent global ifc_ctl_sock override.
Bug: 22307208
Change-Id: Iacffd329ce2a51defa550c7e33277332045a7b9b
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
2015-10-01 14:30:20 -07:00
Elliott Hughes
5ec940aed8
am fb1ecbc5: am e6e71608: Merge "Use __ANDROID__ instead of HAVE_ANDROID_OS."
...
* commit 'fb1ecbc55e7edeafb138eb2a60ca89ba9a7b1f0f':
Use __ANDROID__ instead of HAVE_ANDROID_OS.
2015-07-30 16:50:27 +00:00
Elliott Hughes
145afc2cc4
am fb1ecbc5: am e6e71608: Merge "Use __ANDROID__ instead of HAVE_ANDROID_OS."
...
* commit 'fb1ecbc55e7edeafb138eb2a60ca89ba9a7b1f0f':
Use __ANDROID__ instead of HAVE_ANDROID_OS.
2015-07-30 16:50:15 +00:00
Elliott Hughes
9b828adfad
Use __ANDROID__ instead of HAVE_ANDROID_OS.
...
Change-Id: I9967f3fd758c2a5b40be5b60ae72be7e2fb75136
2015-07-30 09:33:43 -07:00
Elliott Hughes
9e2d8b47c8
am f91c0664: am 421d01c8: am d4196ef8: Merge "Add a command to call libnetutils\' do_dhcp."
...
* commit 'f91c06646ed836c25aeacc4332851c53cd1e0861':
Add a command to call libnetutils' do_dhcp.
2015-04-22 03:32:13 +00:00
Elliott Hughes
9ab372eb22
Add a command to call libnetutils' do_dhcp.
...
Useful for wifi bringup.
Change-Id: Ib1d1b1d15cb9ce57119457a780e169b8f98987c2
2015-04-21 19:31:43 -07:00
Dmitry Shmidt
91dbb7eb6a
am c92420b2: am d9a65a65: Merge "Improving the time to wait for assigning IP address"
...
* commit 'c92420b23b3006ed2e1ece6020dc9d6daa7bf336':
Improving the time to wait for assigning IP address
2015-03-19 00:43:49 +00:00
Dmitry Shmidt
d9a65a6561
Merge "Improving the time to wait for assigning IP address"
2015-03-19 00:26:30 +00:00
Vinit Deshpande
ac56e6ba1d
Merge remote-tracking branch 'goog/mirror-m-wireless-internal-release'
...
Change-Id: I4d3d55dac794db8fa81d3048e41ac589920f43b8
2015-03-16 01:30:49 -07:00
Erik Kline
314d82c3c5
Make sure errmsg starts out null-terminated.
...
Also: clean up some stray trailing whitespace.
Change-Id: I12471b6059971c9c25d7ff6475bfad43cbee44f6
2015-03-04 17:15:28 +09:00
Erik Kline
c2291a7ed3
Refactor dhcp_utils for more flexible uses.
...
Separate out fetching DHCP results from starting the daemon
(for either discover or renew).
Renamed dhcp_do_request() to dhcp_start().
Renamed dhcp_do_request_renew() to dhcp_start_renew().
Added new dhcp_get_results().
Callers of the prior versions of dhcp_do_request* now separately
call dhcp_get_results().
Bug: 19422416
Change-Id: I05447853d444015e6014661dda1bb177b58fe463
2015-03-02 12:26:53 +09:00
daisuke niwa
c855bddc67
Improving the time to wait for assigning IP address
...
Framework always spends 600msec for getting IP address.
DhcpStateMachine.runDhcp calls NetworkUtils.stopDhcp.
After that, it calls NetworkUtils.runDhcp.
In this case, wait_for_property of dhcp_utils.c calls three times.
At least three times, usleep is called.
So move usleep statement after property_get statement.
Change-Id: I77ffb9a5a64875b47bb528b494bb60b68c1acb5a
2015-02-27 09:50:01 +01:00
Nick Kralevich
6d3cddb2e2
More SOCK_CLOEXEC
...
Change-Id: I3e18f34d08a6443aaf55d7c91c27867840ac1773
2015-02-26 13:32:52 -08:00
Yabin Cui
e2d63af002
Move sprintf to snprintf.
...
Bug: 19340053
Change-Id: Id0d866e6195ed4752b4be6081eeb2aab8b1dbe9a
2015-02-17 19:27:51 -08:00
Elliott Hughes
187eade127
Remove netcfg's unused options.
...
Only "netcfg" for a list of interfaces and "netcfg <interface> dhcp" still
seem to be used.
Change-Id: I9f0b580474258fa648deb5287f98d8ec5533ca6f
2015-02-03 11:59:22 -08:00
Elliott Hughes
c463025a19
Revert "Remove netcfg's unused options."
...
This reverts commit f8e83054cb
.
Change-Id: Iede772f96ff9008277df433dcbb5f6603de65283
2015-02-03 19:56:35 +00:00
Elliott Hughes
f8e83054cb
Remove netcfg's unused options.
...
Only "netcfg" for a list of interfaces and "netcfg <interface> dhcp" still
seem to be used.
Change-Id: Iaf499c06b09ffe5e0925339b9cd6e502f3234a86
2015-02-03 11:08:07 -08:00
Elliott Hughes
a744b05984
Add missing <malloc.h> and <string.h> includes.
...
Change-Id: Ia41756e607663d056e7d2fdd7ecbec7e5841a913
2015-01-28 11:37:57 -08:00
Andreas Gampe
a5d5d84773
Libnetutils: Remove unused functions & variables
...
For build-system CFLAGS clean-up, remove unused functions and
variables.
Change-Id: I40a78d5a532dc32b53beb1cfc1b7645bab8add16
2014-11-24 10:43:53 -08:00
Sreeram Ramachandran
17622d09d5
Support resetting connections tied to any nonexistent address.
...
Bug: 15414453
Change-Id: Ibf1f052e12b88838a328148e25817a96f10d50f5
2014-09-08 23:35:52 -07:00
Sreeram Ramachandran
e5ab3e3a4c
Add a comment to not delete seemingly unused code.
...
Change-Id: I5b9d23eea7e850ab5a1f3a4e6c4f8ecdc3844864
2014-07-23 11:33:36 -07:00
Sreeram Ramachandran
eec232603d
Put back some deleted code.
...
http://ag/507249 removed a bunch of supposedly dead (unused) code. It turns out
at least ifc_disable() is being used in some protected partner branches. Put
back that as well as ifc_enable() to keep it symmetric.
Bug: 15413389
Change-Id: Ibec83a66e5d9079876ccf36d250b95b7c0294c03
2014-07-23 09:30:53 -07:00
Sreeram Ramachandran
a723689eca
Cleanup: Delete dead code.
...
Bug: 15413389
Change-Id: I315468832ef18ffc84174e54774ab63b86d284dc
2014-07-22 15:00:21 -07:00
Mark Salyzyn
3c55219b73
am 04482eab: am f998116b: am 08c372d1: Merge "libnetutils: Turn on -Werror"
...
* commit '04482eaba2584c3a05bff4a6647f0a2e55475a91':
libnetutils: Turn on -Werror
2014-05-23 19:43:32 +00:00
Mark Salyzyn
c829080ba9
libnetutils: Turn on -Werror
...
- Get rid of a pair of out of range comparison warnings.
- Turn on -Werror for compilation
Change-Id: Ie6754f41f9348852a02cc0ff35befb5a76ac2883
2014-05-23 07:49:29 -07:00
Mark Salyzyn
51d65e6db9
am 2a7ce0bc: am 9a12e952: am 5b7bb03e: Merge "Revert "libnetutils: Turn on -Werror""
...
* commit '2a7ce0bc7da0201c4b228d04d900ec440bfdcf8b':
Revert "libnetutils: Turn on -Werror"
2014-05-22 00:33:57 +00:00
Mark Salyzyn
fd04f91dff
am d7465194: am 2c0a7f6f: am d3cd08f8: Merge "libnetutils: Turn on -Werror"
...
* commit 'd746519443e37d7dde104779253830e92ae72c8e':
libnetutils: Turn on -Werror
2014-05-22 00:33:56 +00:00
Mark Salyzyn
07dde4c314
Revert "libnetutils: Turn on -Werror"
...
This reverts commit 249c26de82
.
Change-Id: I2a56c574fa8d842d5f3c51fd57ecf078838fcfec
2014-05-21 22:14:38 +00:00
Mark Salyzyn
249c26de82
libnetutils: Turn on -Werror
...
Change-Id: Ie6754f41f9348852a02cc0ff35befb5a76ac2882
2014-05-21 12:58:37 -07:00
Ajay Dudani
1c87ae05b3
libnetutils: Expect 1's complement if computed UDP checksum is zero
...
Per http://tools.ietf.org/html/rfc768 :
If the computed checksum is zero, it is transmitted as all ones (the
equivalent in one's complement arithmetic). An all zero transmitted
checksum value means that the transmitter generated no checksum (for
debugging or for higher level protocols that don't care).
Bug: 10642341
Change-Id: Ib6296dcf3f420f87227047a645c99d9f7ea0d437
2013-12-12 11:24:26 -08:00
The Android Open Source Project
66ed50af68
Merge commit '536dea9d61a032e64bbe584a97463c6638ead009' into HEAD
...
Change-Id: I5c469a4b738629d99d721cad7ded02d6c35f56d5
2013-11-22 13:44:43 -08:00
Elliott Hughes
fc6a1da9a2
am d97a34af: am 60e7d495: Merge "Fix libnetutils to build with clean uapi headers."
...
* commit 'd97a34af49f6beafc21d5f459ea62b499544f9f3':
Fix libnetutils to build with clean uapi headers.
2013-11-12 14:58:50 -08:00
Elliott Hughes
2d640c2640
Fix libnetutils to build with clean uapi headers.
...
(And old ones too.)
Bug: 11559337
Change-Id: Ie61218055bbe07655a9d53c539aa47b85098e42c
2013-11-12 13:05:01 -08:00
Dmitry Shmidt
be06210c50
libnetutils: Get mtu together with dhcp session results
...
Change-Id: I517fd1f62d451b07466a21a2b770d9ce389dac19
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
2013-08-02 14:09:09 -07:00
Colin Cross
0a0a8768cb
resolved conflicts for merge of c0df50af
to stage-aosp-master
...
Change-Id: I949cce9e1f14cd33162b81fbc6728c64e2b09b7c
2013-06-10 15:06:43 -07:00
Michael Wu
897df50f4c
fix bad return value in dhcp_do_request_*
...
1. bad return status make it return uninitialized prefixLength with a magic
number in android_net_utils_runDhcpCommon()
2. it will make DhcpInfoInternal.makeLinkAddress() to throw
IllegalArgumentException when try to connect a Wifi AP
3. the exception will make system reboot, of cource it random.
Change-Id: Iabc0cd5b69c1316f4eeae0aa1b8a91444dca4562
Signed-off-by: Michael Wu <michaelstay@gmail.com>
2013-06-05 08:42:22 +08:00
Ying Wang
083b5ccba3
Add liblog
...
Bug: 8580410
Change-Id: Iab3a9b4307f207c14a04a922cc7350c54e60e9ad
2013-04-09 22:03:45 -07:00