Merge "usb: Fixed the null pointer issue" into tm-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
eb1eb03859
@@ -237,7 +237,12 @@ public class UsbDeviceManager implements ActivityTaskManagerInternal.ScreenObser
|
||||
@Override
|
||||
public void onUEvent(UEventObserver.UEvent event) {
|
||||
if (DEBUG) Slog.v(TAG, "USB UEVENT: " + event.toString());
|
||||
sEventLogger.log(new UsbDeviceLogger.StringEvent("USB UEVENT: " + event.toString()));
|
||||
if (sEventLogger != null) {
|
||||
sEventLogger.log(new UsbDeviceLogger.StringEvent("USB UEVENT: "
|
||||
+ event.toString()));
|
||||
} else {
|
||||
if (DEBUG) Slog.d(TAG, "sEventLogger == null");
|
||||
}
|
||||
|
||||
String state = event.get("USB_STATE");
|
||||
String accessory = event.get("ACCESSORY");
|
||||
|
||||
Reference in New Issue
Block a user