From 04404a37c70f1007779401c2ec697f2ffe50b486 Mon Sep 17 00:00:00 2001 From: Haijie Hong Date: Tue, 9 Apr 2024 14:19:13 +0800 Subject: [PATCH] Use default locale when formatting passkey Bug: 332677725 Test: atest BluetoothPairingControllerTest Change-Id: I21d6606e71eefd2f00994993d3ed277742c5f9b0 --- .../android/settings/bluetooth/BluetoothPairingController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/android/settings/bluetooth/BluetoothPairingController.java b/src/com/android/settings/bluetooth/BluetoothPairingController.java index f75d301ad22..dc7d4dcac26 100644 --- a/src/com/android/settings/bluetooth/BluetoothPairingController.java +++ b/src/com/android/settings/bluetooth/BluetoothPairingController.java @@ -448,7 +448,7 @@ public class BluetoothPairingController implements OnCheckedChangeListener, switch (mType) { case BluetoothDevice.PAIRING_VARIANT_PASSKEY_CONFIRMATION: case BluetoothDevice.PAIRING_VARIANT_DISPLAY_PASSKEY: - return String.format(Locale.US, "%06d", passkey); + return String.format(Locale.getDefault(), "%06d", passkey); case BluetoothDevice.PAIRING_VARIANT_DISPLAY_PIN: return String.format("%04d", passkey);