diff options
author | Stefan Weil <sw@weilnetz.de> | 2013-12-11 21:37:11 +0100 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2013-12-13 14:49:50 +0100 |
commit | f671d173c7e1da555b693e8b14f3ed0852601809 (patch) | |
tree | e3add2447d4ad3ba901cff9eb16ba4d9c7e28df3 /migration-fd.c | |
parent | 01443e1388971999514511a26f9d36a7cdaa2cc2 (diff) |
block/vvfat: Fix compiler warnings for OpenBSD
The buildbot shows these compiler warnings:
block/vvfat.c: In function 'create_short_and_long_name':
block/vvfat.c:620: warning: array size (8) smaller than bound length (11)
block/vvfat.c:620: warning: array size (8) smaller than bound length (11)
block/vvfat.c:635: warning: array size (8) smaller than bound length (11)
block/vvfat.c:635: warning: array size (8) smaller than bound length (11)
They are caused by tricky code where 8 characters for the name are followed
by 3 characters for the extension, and some operations touch both name and
extension.
Using an 11 character name which includes the extension fixes the compiler
warning, satisfies cppcheck, valgrind and maybe other static and dynamic
code checkers, and even simplifies some parts of the code.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'migration-fd.c')
0 files changed, 0 insertions, 0 deletions