mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2026-04-27 04:21:42 +00:00
Fixed incorrect progress for downloading
This commit is contained in:
parent
456da82f2f
commit
77bace907c
1 changed files with 6 additions and 0 deletions
|
|
@ -280,6 +280,7 @@ void network_receive_download(struct Packet* p) {
|
|||
packet_read(p, &chunk, sizeof(u8) * chunkLength);
|
||||
|
||||
// mark the offset group as received
|
||||
bool foundGroup = false;
|
||||
for (u64 i = 0; i < 2; i++) {
|
||||
struct OffsetGroup* og = &sOffsetGroup[i];
|
||||
for (u64 j = 0; j < OFFSET_COUNT; j++) {
|
||||
|
|
@ -296,6 +297,11 @@ void network_receive_download(struct Packet* p) {
|
|||
}
|
||||
after_group:;
|
||||
|
||||
if (!foundGroup) {
|
||||
LOG_INFO("Received chunk from an inactive offset group");
|
||||
return;
|
||||
}
|
||||
|
||||
// write the chunk
|
||||
u64 chunkPour = 0;
|
||||
u64 fileStartOffset = 0;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue