mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2026-05-04 21:08:07 +02:00
util: put limits on how many strings we join
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
6ad928a1b6
commit
24a19dd167
1 changed files with 2 additions and 0 deletions
|
|
@ -595,6 +595,8 @@ strv_join(char **strv, const char *joiner)
|
||||||
|
|
||||||
assert(slen < 1000);
|
assert(slen < 1000);
|
||||||
assert(strlen(joiner) < 1000);
|
assert(strlen(joiner) < 1000);
|
||||||
|
assert(count > 0);
|
||||||
|
assert(count < 100);
|
||||||
|
|
||||||
slen += (count - 1) * strlen(joiner);
|
slen += (count - 1) * strlen(joiner);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue