mpegtsenc: Don't pass NULL to memcpy
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
This commit is contained in:
parent
3b3501f75c
commit
fde9013ab4
1 changed files with 4 additions and 0 deletions
|
|
@ -277,6 +277,10 @@ static void putstr8(uint8_t **q_ptr, const char *str, int write_len)
|
|||
len = strlen(str);
|
||||
if (write_len)
|
||||
*q++ = len;
|
||||
if (!str) {
|
||||
*q_ptr = q;
|
||||
return;
|
||||
}
|
||||
memcpy(q, str, len);
|
||||
q += len;
|
||||
*q_ptr = q;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue