mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-13 10:02:38 +00:00
Fix potential buffer overflow.
PR: bin/14697 Submitted by: Matthew <kienow@infinet.com>
This commit is contained in:
parent
6db345b90e
commit
db7edb3137
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=132608
@ -153,8 +153,8 @@ vinum_read(int argc, char *argv[], char *arg0[])
|
||||
buffer[0] = '\0'; /* make sure we don't pass anything */
|
||||
if (argc > 0) { /* args specified, */
|
||||
for (i = 0; i < argc; i++) { /* each drive name */
|
||||
strcat(buffer, argv[i]);
|
||||
strcat(buffer, " ");
|
||||
strlcat(buffer, argv[i], sizeof(buffer));
|
||||
strlcat(buffer, " ", sizeof(buffer));
|
||||
}
|
||||
}
|
||||
ioctl(superdev, VINUM_READCONFIG, &buffer);
|
||||
|
Loading…
Reference in New Issue
Block a user