Correct minor issues reported by the analyzer.
Found with the Clang Static Analyzer.
This commit is contained in:
committed by
Axel Wagner
parent
64f2a7561d
commit
c8032d552d
@ -248,7 +248,8 @@ int i3_send_msg(uint32_t type, const char *payload) {
|
||||
memcpy(walk, &type, sizeof(uint32_t));
|
||||
walk += sizeof(uint32_t);
|
||||
|
||||
strncpy(walk, payload, len);
|
||||
if (payload != NULL)
|
||||
strncpy(walk, payload, len);
|
||||
|
||||
uint32_t written = 0;
|
||||
|
||||
|
Reference in New Issue
Block a user