mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-04-21 06:46:38 -04:00
Apply 1 suggestion(s) to 1 file(s)
Co-authored-by: Barnabás Pőcze <pobrn@protonmail.com>
This commit is contained in:
parent
0a38fedeec
commit
c5e1a3eae3
1 changed files with 1 additions and 4 deletions
|
|
@ -918,10 +918,7 @@ static char **pw_strv_insert_at(char **strv, int len, int pos, const char *str)
|
|||
while (strv != NULL && strv[len] != NULL)
|
||||
len++;
|
||||
}
|
||||
|
||||
if (pos < 0)
|
||||
pos = 0;
|
||||
else if (pos > len)
|
||||
if (pos < 0 || pos > len)
|
||||
pos = len;
|
||||
|
||||
n = realloc(strv, sizeof(char*) * (len + 2));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue