Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
KazukiPrzyborowski authored Mar 5, 2024
1 parent 2f13a6f commit 2d16af1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pycatfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -2188,6 +2188,7 @@ def ArchiveFileSeekToFile(infile, seekto=0, skipchecksum=False, formatspecs=__fi
if(seekto>=0):
il = -1;
while(il < seekto):
seekstart = catfp.tell();
preheaderdata = ReadFileHeaderData(catfp, 5, formatspecs[4]);
prefheadsize = int(preheaderdata[0], 16);
prefseek = prefheadsize - (int(len(preheaderdata[1]) + 1) + int(len(preheaderdata[2]) + 1) + int(len(preheaderdata[3]) + 1) + int(len(preheaderdata[4]) + 1));
Expand All @@ -2198,6 +2199,7 @@ def ArchiveFileSeekToFile(infile, seekto=0, skipchecksum=False, formatspecs=__fi
catfp.seek(prefsize, 1);
catfp.seek(1, 1);
il = il + 1;
catfp.seek(seekstart, 0);
fileidnum = seekto;
catfheadsize = int(preheaderdata[0], 16);
catftype = int(preheaderdata[1], 16);
Expand Down

0 comments on commit 2d16af1

Please sign in to comment.