mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-26 22:20:46 +00:00
Fixed #2142 XML Export - string values containing only spaces
Fixed AS3 - Nullpointer in MethodBody when no ABC set
This commit is contained in:
@@ -144,13 +144,15 @@ public final class MethodBody implements Cloneable {
|
||||
}
|
||||
}
|
||||
|
||||
public synchronized AVM2Code getCode() {
|
||||
public synchronized AVM2Code getCode() {
|
||||
if (code == null) {
|
||||
AVM2Code avm2Code;
|
||||
try {
|
||||
ABCInputStream ais = new ABCInputStream(new MemoryInputStream(codeBytes));
|
||||
avm2Code = new AVM2Code(ais, this);
|
||||
avm2Code.removeWrongIndices(abc.constants);
|
||||
if (abc != null) {
|
||||
avm2Code.removeWrongIndices(abc.constants);
|
||||
}
|
||||
} catch (UnknownInstructionCode | IOException ex) {
|
||||
avm2Code = new AVM2Code();
|
||||
logger.log(Level.SEVERE, null, ex);
|
||||
|
||||
@@ -53,7 +53,7 @@ import javax.xml.stream.XMLStreamWriter;
|
||||
public class SwfXmlExporter {
|
||||
|
||||
public static final int XML_EXPORT_VERSION_MAJOR = 2;
|
||||
public static final int XML_EXPORT_VERSION_MINOR = 0;
|
||||
public static final int XML_EXPORT_VERSION_MINOR = 1;
|
||||
|
||||
private static final Logger logger = Logger.getLogger(SwfXmlExporter.class.getName());
|
||||
|
||||
@@ -158,7 +158,7 @@ public class SwfXmlExporter {
|
||||
|
||||
if (isListItem) {
|
||||
writer.writeStartElement(name);
|
||||
writer.writeCharacters(stringValue);
|
||||
writer.writeCharacters(stringValue);
|
||||
writer.writeEndElement();
|
||||
} else {
|
||||
writer.writeAttribute(name, stringValue);
|
||||
|
||||
Reference in New Issue
Block a user