diff options
author | Nick Kralevich <nnk@google.com> | 2010-12-08 10:08:22 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2010-12-08 10:08:22 -0800 |
commit | ba82088b13aae4cdf1217e499eb9fb0eb6977da4 (patch) | |
tree | b0b51ee2a455275b821c55d653362989b5e3ae97 /telephony/java | |
parent | c948d07b2a0f2bfdbe999bc1baa2ee4b2de513e6 (diff) | |
parent | 1234ce117adc6fef495688ed8032c43e77445f90 (diff) | |
download | frameworks_base-ba82088b13aae4cdf1217e499eb9fb0eb6977da4.zip frameworks_base-ba82088b13aae4cdf1217e499eb9fb0eb6977da4.tar.gz frameworks_base-ba82088b13aae4cdf1217e499eb9fb0eb6977da4.tar.bz2 |
Merge "Modify emergency number detection"
Diffstat (limited to 'telephony/java')
-rw-r--r-- | telephony/java/android/telephony/PhoneNumberUtils.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/telephony/java/android/telephony/PhoneNumberUtils.java b/telephony/java/android/telephony/PhoneNumberUtils.java index 893ae88..ad2a887 100644 --- a/telephony/java/android/telephony/PhoneNumberUtils.java +++ b/telephony/java/android/telephony/PhoneNumberUtils.java @@ -1497,7 +1497,7 @@ public class PhoneNumberUtils // searches through the comma-separated list for a match, // return true if one is found. for (String emergencyNum : numbers.split(",")) { - if (emergencyNum.equals(number)) { + if (number.startsWith(emergencyNum)) { return true; } } @@ -1506,7 +1506,7 @@ public class PhoneNumberUtils } //no ecclist system property, so use our own list. - return (number.equals("112") || number.equals("911")); + return (number.startsWith("112") || number.startsWith("911")); } /** |