Fixed ftl.dat parsing when 0-byte resources are present
This commit is contained in:
parent
e76b0c67bd
commit
19233266d0
3 changed files with 12 additions and 1 deletions
|
@ -11,6 +11,13 @@
|
|||
"notice" : "Reminder: Return FTL to an unmodded state before upgrading SMM.\nAnd delete SMM's backups when upgrading FTL."
|
||||
},
|
||||
"changelog" : [
|
||||
{
|
||||
"version" : "1.9.2",
|
||||
"hidden" : true,
|
||||
"changes" : [
|
||||
"Fixed ftl.dat parsing when 0-byte resources are present"
|
||||
]
|
||||
},
|
||||
{
|
||||
"version" : "1.9.1",
|
||||
"hidden" : false,
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
Changelog
|
||||
|
||||
1.9.2:
|
||||
- Fixed ftl.dat parsing when 0-byte resources are present
|
||||
|
||||
1.9.1:
|
||||
- Edited a comment in boilerplate mod metadata to include AE ships
|
||||
- Made the comments in boilerplace mod metadata optional
|
||||
|
|
|
@ -419,7 +419,7 @@ public class PkgPack extends AbstractPack {
|
|||
entry.dataSize = readBigUInt();
|
||||
entry.unpackedSize = readBigUInt();
|
||||
|
||||
if ( entry.dataSize == 0 ) { // Null entry, dat wasn't repacked.
|
||||
if ( entry.dataOffset == 0 ) { // Null entry, dat wasn't repacked.
|
||||
entryList.add( null );
|
||||
} else {
|
||||
entryList.add( entry );
|
||||
|
@ -434,6 +434,7 @@ public class PkgPack extends AbstractPack {
|
|||
|
||||
for ( int i=0; i < entryCount; i++ ) {
|
||||
PkgEntry entry = entryList.get( i );
|
||||
if ( entry == null ) continue;
|
||||
|
||||
bigByteBuf.position( entry.innerPathOffset );
|
||||
entry.innerPath = readNullTerminatedString( bigByteBuf );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue