Add some logging to NDC.
We're getting some lockups of netd and this can help point us in the right direction. bug:5864209 Change-Id: Id8bdb0a758c5b161e0143de61b5f39c3a982e329
This commit is contained in:
@@ -153,6 +153,10 @@ final class NativeDaemonConnector implements Runnable, Handler.Callback, Watchdo
|
|||||||
start = i + 1;
|
start = i + 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (start == 0) {
|
||||||
|
final String rawEvent = new String(buffer, start, count, Charsets.UTF_8);
|
||||||
|
log("RCV incomplete <- {" + rawEvent + "}");
|
||||||
|
}
|
||||||
|
|
||||||
// We should end at the amount we read. If not, compact then
|
// We should end at the amount we read. If not, compact then
|
||||||
// buffer and read again.
|
// buffer and read again.
|
||||||
@@ -297,7 +301,11 @@ final class NativeDaemonConnector implements Runnable, Handler.Callback, Watchdo
|
|||||||
throws NativeDaemonConnectorException {
|
throws NativeDaemonConnectorException {
|
||||||
final ArrayList<NativeDaemonEvent> events = Lists.newArrayList();
|
final ArrayList<NativeDaemonEvent> events = Lists.newArrayList();
|
||||||
|
|
||||||
mResponseQueue.clear();
|
while (mResponseQueue.size() > 0) {
|
||||||
|
try {
|
||||||
|
log("ignoring {" + mResponseQueue.take() + "}");
|
||||||
|
} catch (Exception e) {}
|
||||||
|
}
|
||||||
|
|
||||||
final String sentCommand = sendCommandLocked(cmd, args);
|
final String sentCommand = sendCommandLocked(cmd, args);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user