#443 fix bug in new calculated offset which caused xref issue

This commit is contained in:
Eliot Jones
2022-04-24 13:19:32 -04:00
parent 8ca0ed3842
commit 2576c3d838
2 changed files with 2 additions and 2 deletions

View File

@@ -170,7 +170,7 @@ three %PDF-1.6");
var result = FileHeaderParser.Parse(scanner.scanner, scanner.bytes, false, log);
Assert.Equal(0, scanner.scanner.CurrentPosition);
Assert.Equal(129, result.OffsetInFile);
Assert.Equal(128, result.OffsetInFile);
Assert.Equal(1.1m, result.Version);
Assert.Equal("PDF-1.1", result.VersionString);
}

View File

@@ -131,7 +131,7 @@
headerVersion = new HeaderVersion(
version,
content.Substring(afterCommentSymbolIndex, versionLength - 1),
currentOffset + afterCommentSymbolIndex);
currentOffset + actualIndex);
inputBytes.Seek(startPosition);