Skip to content

Commit

Permalink
Binary mode: Fix progressive import/export last ID assignment (#29)
Browse files Browse the repository at this point in the history
set last ID before asking for more data so we know if we get stuck

Co-authored-by: Gareth Potter <gareth.potter@brillpower.com>
  • Loading branch information
garethpotter and garethpotter committed Apr 10, 2024
1 parent f320a8b commit dc5c398
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/thingset_bin.c
Original file line number Diff line number Diff line change
Expand Up @@ -848,6 +848,7 @@ int thingset_bin_import_data_progressively(struct thingset_context *ts, uint8_t
ts->decoder->payload = ts->msg;
ts->decoder->elem_count = state.elem_count;
*consumed = successfully_parsed_bytes;
*last_id = id;
return 1; /* ask for more data */
}
}
Expand Down

0 comments on commit dc5c398

Please sign in to comment.