Fix incorrect reading of multichoice app restrictions

Clear the list of choices values before putting new ones in.

Bug: 17299310
Change-Id: I01051d1703adcbdd7d0b5fb4ee423404f98489e8
This commit is contained in:
Amith Yamasani
2014-08-27 10:33:17 -07:00
parent 0dedb722e6
commit e084039dd2

View File

@@ -1576,6 +1576,7 @@ public class UserManagerService extends IUserManager.Stub {
String valType = parser.getAttributeValue(null, ATTR_VALUE_TYPE);
String multiple = parser.getAttributeValue(null, ATTR_MULTIPLE);
if (multiple != null) {
values.clear();
int count = Integer.parseInt(multiple);
while (count > 0 && (type = parser.next()) != XmlPullParser.END_DOCUMENT) {
if (type == XmlPullParser.START_TAG