Skip to content

Buffer overflow in topic/type name#38

Open
BenediktConze wants to merge 1 commit intoembedded-software-laboratory:masterfrom
BenediktConze:fix_strlen_null_character
Open

Buffer overflow in topic/type name#38
BenediktConze wants to merge 1 commit intoembedded-software-laboratory:masterfrom
BenediktConze:fix_strlen_null_character

Conversation

@BenediktConze
Copy link
Contributor

strlen doesn't count the trailing null character of a string, therefore the char array for topic/type name must be one element longer than the result of strlen, or else the null character might be written outside the buffer.

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