Fix bug 5563362: failed to initialize external account type
The contacts.xml parser has had a bug that it processes each ContactsDataKind tag twice,for START_TAG and for END_TAG. When processing for END_TAG, because an end tag doesn't have attributes it created an empty DataKind, with null mimetype. (This bug existed even before the EditSchema change, meaning MR0 still has this issue.) Before MR1 this null mimetype was just not used anywhere, so it was okay. But in MR1 we have the duplicate mimetype check, and it will complain if a contacts.xml has more than one ContactsDataKind therefore has multiple "null" mimetype definitions. Made sure to only process for START_TAG. Also cleaned up existing code with a similar check. Also included the package name in the error message for duplicated mimetypes. Bug 5563362 Change-Id: Ib68fb0dca03784c4d7976ac8bf68b1dce5305b03
Loading
Please register or sign in to comment