mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-26 11:20:54 +00:00
generic tag panel: binary editor now can edit byte[]
This commit is contained in:
@@ -23,6 +23,8 @@ import com.jpexs.decompiler.flash.types.BasicType;
|
||||
import com.jpexs.decompiler.flash.types.annotations.SWFType;
|
||||
import com.jpexs.helpers.ByteArrayRange;
|
||||
import java.io.IOException;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -72,6 +74,10 @@ public class DebugIDTag extends Tag {
|
||||
*/
|
||||
@Override
|
||||
public void getData(SWFOutputStream sos) throws IOException {
|
||||
if (debugId.length != 16) {
|
||||
Logger.getLogger(DebugIDTag.class.getName()).log(Level.WARNING, "DebugID should be 16 bytes");
|
||||
}
|
||||
|
||||
sos.write(debugId);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,6 +25,8 @@ import com.jpexs.decompiler.flash.types.annotations.Reserved;
|
||||
import com.jpexs.decompiler.flash.types.annotations.SWFType;
|
||||
import com.jpexs.helpers.ByteArrayRange;
|
||||
import java.io.IOException;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
/**
|
||||
* Enable flash profiling information
|
||||
@@ -71,6 +73,10 @@ public class EnableTelemetryTag extends Tag {
|
||||
public final void readData(SWFInputStream sis, ByteArrayRange data, int level, boolean parallel, boolean skipUnusualTags, boolean lazy) throws IOException {
|
||||
reserved = (int) sis.readUB(16, "reserved");
|
||||
if (sis.available() > 0) {
|
||||
if (passwordHash.length != 32) {
|
||||
Logger.getLogger(EnableTelemetryTag.class.getName()).log(Level.WARNING, "PasswordHash should be 32 bytes");
|
||||
}
|
||||
|
||||
passwordHash = sis.readBytesEx(32, "passwordHash");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user