Merge "prevent ioctl_init() to write outside buffer"

gugelfrei
Elliott Hughes 10 years ago committed by Gerrit Code Review
commit d55d8dac45

@ -327,7 +327,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…
Cancel
Save