Skip to content

Commit

Permalink
cborencoder: Fix cbor_encode_raw
Browse files Browse the repository at this point in the history
`append_to_buffer` now expects to be told what we're appending, since
the docs here say `raw` must be valid CBOR, it seems
`CborEncoderAppendCborData` is the most appropriate value here.
  • Loading branch information
sjlongland committed Jun 21, 2024
1 parent e980a75 commit ec1ebfe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cborencoder.c
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,7 @@ CborError cbor_encode_byte_string(CborEncoder *encoder, const uint8_t *string, s
*/
CborError cbor_encode_raw(CborEncoder *encoder, const uint8_t *raw, size_t length)
{
return append_to_buffer(encoder, raw, length);
return append_to_buffer(encoder, raw, length, CborEncoderAppendCborData);
}

/**
Expand Down

0 comments on commit ec1ebfe

Please sign in to comment.