diff options
author | Eric Anholt <eric@anholt.net> | 2018-08-01 11:25:58 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2018-08-01 11:39:19 -0700 |
commit | c2eab33b088f90cb66802a9e96e92305cccebdc7 (patch) | |
tree | 14a65119505e194ff1a97953fe3f03c3f5e7a2af /src/broadcom | |
parent | d74227056497cae04fa28bb1c27d9f9dd07526bd (diff) |
v3d: Actually put the "%s" in the snprintf.
I missed an important part when porting the change over, fixing my
compiler warning but breaking -Werror=format-security.
Fixes: e6ff5ac4468e ("v3d: use snprintf(..., "%s", ...) instead of strncpy")
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107443
Diffstat (limited to 'src/broadcom')
-rw-r--r-- | src/broadcom/cle/v3d_decoder.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/broadcom/cle/v3d_decoder.c b/src/broadcom/cle/v3d_decoder.c index 4496388e319..373a1d99644 100644 --- a/src/broadcom/cle/v3d_decoder.c +++ b/src/broadcom/cle/v3d_decoder.c @@ -834,7 +834,7 @@ iter_advance_field(struct v3d_field_iterator *iter) iter->field = iter->group->fields[iter->field_iter++]; if (iter->field->name) - snprintf(iter->name, sizeof(iter->name), iter->field->name); + snprintf(iter->name, sizeof(iter->name), "%s", iter->field->name); else memset(iter->name, 0, sizeof(iter->name)); iter->offset = iter_group_offset_bits(iter, iter->group_iter) / 8 + |