projects
/
fio.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
diskutil: fix potential out-of-bounds array write
[fio.git]
/
diskutil.c
diff --git
a/diskutil.c
b/diskutil.c
index 9aa1fa15acab9ed27d0925e2926816bd8478d90e..cbde42e908f71629cd9575e783fb4d390554f369 100644
(file)
--- a/
diskutil.c
+++ b/
diskutil.c
@@
-236,7
+236,7
@@
static void find_add_disk_slaves(struct thread_data *td, char *path,
* are links to the real directories for the slave
* devices?
*/
- linklen = readlink(temppath, slavepath, PATH_MAX -
0
);
+ linklen = readlink(temppath, slavepath, PATH_MAX -
1
);
if (linklen < 0) {
perror("readlink() for slave device.");
return;