mirror of
https://github.com/revanced/Apktool.git
synced 2025-01-21 09:17:35 +01:00
Add new line at the end of decoded XML file.
This commit is contained in:
parent
26cdc8299a
commit
e1f3ab852a
@ -249,7 +249,7 @@ final public class AndrolibResources {
|
||||
}
|
||||
|
||||
private void generateValuesFile(ResValuesFile valuesFile, Directory out,
|
||||
XmlSerializer serial) throws AndrolibException {
|
||||
ExtXmlSerializer serial) throws AndrolibException {
|
||||
try {
|
||||
OutputStream outStream = out.getFileOutput(valuesFile.getPath());
|
||||
serial.setOutput((outStream), null);
|
||||
@ -265,6 +265,7 @@ final public class AndrolibResources {
|
||||
}
|
||||
|
||||
serial.endTag(null, "resources");
|
||||
serial.newLine();
|
||||
serial.endDocument();
|
||||
serial.flush();
|
||||
outStream.close();
|
||||
|
@ -17,8 +17,8 @@
|
||||
package brut.androlib.res.decoder;
|
||||
|
||||
import brut.androlib.AndrolibException;
|
||||
import brut.androlib.res.util.ExtXmlSerializer;
|
||||
import java.io.*;
|
||||
import java.util.logging.Logger;
|
||||
import org.xmlpull.v1.*;
|
||||
import org.xmlpull.v1.wrapper.*;
|
||||
|
||||
@ -27,7 +27,7 @@ import org.xmlpull.v1.wrapper.*;
|
||||
*/
|
||||
public class XmlPullStreamDecoder implements ResStreamDecoder {
|
||||
public XmlPullStreamDecoder(XmlPullParser parser,
|
||||
XmlSerializer serializer) {
|
||||
ExtXmlSerializer serializer) {
|
||||
this.mParser = parser;
|
||||
this.mSerial = serializer;
|
||||
}
|
||||
@ -45,6 +45,7 @@ public class XmlPullStreamDecoder implements ResStreamDecoder {
|
||||
while (par.nextToken() != XmlPullParser.END_DOCUMENT) {
|
||||
ser.event(par);
|
||||
}
|
||||
mSerial.newLine();
|
||||
ser.flush();
|
||||
} catch (XmlPullParserException ex) {
|
||||
throw new AndrolibException("Could not decode XML", ex);
|
||||
@ -54,5 +55,5 @@ public class XmlPullStreamDecoder implements ResStreamDecoder {
|
||||
}
|
||||
|
||||
private final XmlPullParser mParser;
|
||||
private final XmlSerializer mSerial;
|
||||
private final ExtXmlSerializer mSerial;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user