Fix incorrect APP1 segment size calculation.

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7981 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2021-03-24 16:55:19 +00:00
parent dbe26c3b9b
commit 8312fda08f

View File

@ -225,6 +225,7 @@ begin
// the segment size must be written, we calculate the size of the segment // the segment size must be written, we calculate the size of the segment
startPos := ASegmentStartPos + SizeOf(word); startPos := ASegmentStartPos + SizeOf(word);
segmentSize := AStream.Position - startPos; segmentSize := AStream.Position - startPos;
segmentSize := segmentSize - 2; // skip two marker bytes
// Move the stream to where the segment size must be written... // Move the stream to where the segment size must be written...
AStream.Position := startPos; AStream.Position := startPos;