Fixes errors

This commit is contained in:
Sergey Toshin
2018-06-05 17:06:55 +03:00
parent d20cd43a99
commit 0a0c4eac88
2 changed files with 4 additions and 10 deletions
@@ -119,13 +119,6 @@ public class CodeWriter {
buf.append(code.buf);
return this;
}
public void updateContent(String newData) {
offset = newData.length();
buf = new StringBuilder(newData);
line = newData.split(NL).length + 1;
code = newData;
}
public CodeWriter newLine() {
addLine();
@@ -251,8 +251,8 @@ public class BinaryXMLParser extends CommonBinaryParser {
}
isOneLine = true;
isLastEnd = false;
currentTag = getValidTagAttributeName(getString(startNSName));
currentTag = deobfClassName(currentTag);
currentTag = deobfClassName(getString(startNSName));
currentTag = getValidTagAttributeName(currentTag);
writer.startLine("<").add(currentTag);
writer.attachSourceLine(elementBegLineNumber);
int attributeStart = is.readInt16();
@@ -441,7 +441,8 @@ public class BinaryXMLParser extends CommonBinaryParser {
int comment = is.readInt32();
int elementNS = is.readInt32();
int elementNameId = is.readInt32();
String elemName = getValidTagAttributeName(getString(elementNameId));
String elemName = deobfClassName(getString(elementNameId));
elemName = getValidTagAttributeName(elemName);
if (currentTag.equals(elemName) && isOneLine && !isLastEnd) {
writer.add("/>");
} else {