Cleanup Netd to prevent getting hung.

If the sending of the command fails we should note it and not wait forever
for the response.

We should also not say we're ready until we actually are.

bug:2993205
Change-Id: I380f0312ac4693ad184a526b330fdfa23f6ac558
This commit is contained in:
Robert Greenwalt
2010-09-22 14:32:35 -07:00
parent b2044da3f9
commit e5c3afb292
3 changed files with 34 additions and 8 deletions

View File

@@ -254,7 +254,8 @@ class ServerThread extends Thread {
try {
Slog.i(TAG, "NetworkManagement Service");
ServiceManager.addService(
Context.NETWORKMANAGEMENT_SERVICE, new NetworkManagementService(context));
Context.NETWORKMANAGEMENT_SERVICE,
NetworkManagementService.create(context));
} catch (Throwable e) {
Slog.e(TAG, "Failure starting NetworkManagement Service", e);
}