Display and control your Android device
Ignore low-FPS ranges if not available
Romain Vimont538764416099
diff --git a/server/src/main/java/com/genymobile/scrcpy/util/LogUtils.java b/server/src/main/java/com/genymobile/scrcpy/util/LogUtils.javaindex 961b8da0..701ae373 100644--- a/server/src/main/java/com/genymobile/scrcpy/util/LogUtils.java+++ b/server/src/main/java/com/genymobile/scrcpy/util/LogUtils.java@@ -163,8 +163,10 @@ public final class LogUtils {try {// Capture frame rates for low-FPS mode are the same for every resolutionRange<Integer>[] lowFpsRanges = characteristics.get(CameraCharacteristics.CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES);- SortedSet<Integer> uniqueLowFps = getUniqueSet(lowFpsRanges);- builder.append(", fps=").append(uniqueLowFps);+ if (lowFpsRanges != null) {+ SortedSet<Integer> uniqueLowFps = getUniqueSet(lowFpsRanges);+ builder.append(", fps=").append(uniqueLowFps);+ }} catch (Exception e) {// Some devices may provide invalid ranges, causing an IllegalArgumentException "lower must be less than or equal to upper"Ln.w("Could not get available frame rates for camera " + id, e);