summaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorThe Android Open Source Project <initial-contribution@android.com>2010-04-22 11:43:17 -0700
committerThe Android Open Source Project <initial-contribution@android.com>2010-04-22 11:43:17 -0700
commit5ebaf10693725c9dc48219c3c65945b84d74692f (patch)
tree5124cb6169287afd69e85a4082cea2dce4d41c22 /packages
parentd9b802bd03d0ef4792bc99289f16f6a05bd1ee95 (diff)
parent392fc3573553b71dc5c2712aca16e262efd33ce9 (diff)
downloadframeworks_base-5ebaf10693725c9dc48219c3c65945b84d74692f.zip
frameworks_base-5ebaf10693725c9dc48219c3c65945b84d74692f.tar.gz
frameworks_base-5ebaf10693725c9dc48219c3c65945b84d74692f.tar.bz2
merge from open-source master
Change-Id: I2a3a06f0bd3530f9c0d3cb64ca6a87913649d64b
Diffstat (limited to 'packages')
-rw-r--r--packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
index 1b4ba81..1019fa8 100644
--- a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
+++ b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
@@ -399,9 +399,12 @@ public class SettingsProvider extends ContentProvider {
}
} else if (prefix == '-' && index >= 0) {
// remove the provider from the list if present
- // remove leading and trailing commas
- if (index > 0) index--;
- if (end < providers.length()) end++;
+ // remove leading or trailing comma
+ if (index > 0) {
+ index--;
+ } else if (end < providers.length()) {
+ end++;
+ }
newProviders = providers.substring(0, index);
if (end < providers.length()) {