Skip to content

Commit

Permalink
no op when message is NULL
Browse files Browse the repository at this point in the history
  • Loading branch information
knok committed Jul 7, 2019
1 parent 2df6437 commit e903c93
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/status.c
Expand Up @@ -68,6 +68,8 @@ sixel_helper_set_additional_message(
{
size_t len;

if (message == 0)
return;
len = strlen(message);
memcpy(g_buffer, message, len < sizeof(g_buffer) ? len: sizeof(g_buffer) - 1);
g_buffer[sizeof(g_buffer) - 1] = 0;
Expand Down

0 comments on commit e903c93

Please sign in to comment.