Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

decoder: fix nanocbor_skip() for tags #91

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

mguetschow
Copy link
Contributor

As per RFC8949, tags consist of both a tag number and an enclosed data item. When skipping a tag, the enclosed data item should be skipped, too.

This PR adds several tests for nanocbor_skip() for (nested) arrays and maps, and fixes the behavior when skipping a CBOR tag: It now skips the enclosed data item and only decrements it->remaining by one (if applicable).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant