Andreas Schildbach 2012-09-19 12:33:50 +02:00
parent 6ac291eb5f
commit 946414a760
2 changed files with 11 additions and 2 deletions

View file

@ -301,7 +301,15 @@ public final class XmlPullUtil
throw new XmlPullParserException("name for element can not be null");
pp.require(XmlPullParser.START_TAG, namespace, name);
return pp.nextText();
final String text = pp.nextText();
// work around http://code.google.com/p/android/issues/detail?id=21425
if (pp.getEventType() != XmlPullParser.END_TAG)
pp.nextTag();
pp.require(XmlPullParser.END_TAG, namespace, name);
return text;
}
/**