mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-06 04:30:10 +01:00
gallium/utils: silence strncpy warning
Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4584>
This commit is contained in:
parent
dbfeec62c3
commit
07071cac7b
1 changed files with 1 additions and 1 deletions
|
|
@ -234,7 +234,7 @@ debug_symbol_name_glibc(const void *addr, char* buf, unsigned size)
|
|||
if (!syms) {
|
||||
return FALSE;
|
||||
}
|
||||
strncpy(buf, syms[0], size);
|
||||
strncpy(buf, syms[0], size - 1);
|
||||
buf[size - 1] = 0;
|
||||
free(syms);
|
||||
return TRUE;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue