mirror of
https://github.com/aaru-dps/libaaruformat.git
synced 2025-12-16 19:24:40 +00:00
Fix memcpy destination offset in writing buffer to ensure correct data placement
This commit is contained in:
@@ -112,7 +112,7 @@ int32_t aaruf_write_sector(void *context, uint64_t sectorAddress, uint8_t *data,
|
||||
}
|
||||
|
||||
TRACE("Copying data to writing buffer at position %zu", ctx->writingBufferPosition);
|
||||
memcpy(ctx->writingBuffer, data, length);
|
||||
memcpy(ctx->writingBuffer + ctx->writingBufferPosition, data, length);
|
||||
TRACE("Advancing writing buffer position to %zu", ctx->writingBufferPosition + length);
|
||||
ctx->writingBufferPosition += length;
|
||||
TRACE("Advancing current block offset to %zu", ctx->currentBlockOffset + 1);
|
||||
|
||||
Reference in New Issue
Block a user