device_google_zuma/usb/usb
Kuen-Han Tsai 23cee311f9 Usb: Add status check to prevent NPE
This patch prevents a Null Pointer Exception in
queryMoistureDetectionStatus() when getPortStatusHelper() fails to open
the /sys/class/typec file. The failure results in an empty
currentPortStatus vector, causing the NPE when accessing its first
element.

Bug: 361097811
Flag: EXEMPT bugfix
Test: NPE does not occur when getPortStatusHelper() fails
Change-Id: I2cbe70d3b00cb2cf8c28a28d91a18fbf7c326ea7
Signed-off-by: Kuen-Han Tsai <khtsai@google.com>
2024-10-09 15:59:20 +08:00
..
Android.bp switch over to use new storage read api instead of 2024-06-07 13:07:42 +00:00
android.hardware.usb-service.rc Fix permissions for dp_hotplug_error_code sysfs node 2024-02-14 00:58:35 +00:00
android.hardware.usb-service.xml usb: update usb hal version to v3 2023-11-14 20:41:47 +00:00
service.cpp Branch zuma from gs201 2022-04-19 12:45:55 +08:00
Usb.cpp Usb: Add status check to prevent NPE 2024-10-09 15:59:20 +08:00
Usb.h usb: Log for retry on role switch 2024-06-13 16:54:37 +08:00
UsbDataSessionMonitor.cpp usb: dump flag value in the constructor 2024-01-10 08:50:07 +00:00
UsbDataSessionMonitor.h usb: implement heuristics to flag data compliance warnings 2023-12-26 22:25:25 +00:00