am d55d8dac
: Merge "prevent ioctl_init() to write outside buffer"
* commit 'd55d8dac45dc60cb2cc9e599d3e89532db0cfc39': prevent ioctl_init() to write outside buffer
This commit is contained in:
commit
33b6de4b94
1 changed files with 1 additions and 1 deletions
|
@ -333,7 +333,7 @@ static void ioctl_init(struct dm_ioctl *io, size_t dataSize, const char *name, u
|
|||
io->version[2] = 0;
|
||||
io->flags = flags;
|
||||
if (name) {
|
||||
strncpy(io->name, name, sizeof(io->name));
|
||||
strlcpy(io->name, name, sizeof(io->name));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue