projects
/
fio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2fd973c
)
diskutil: fix potential out-of-bounds array write
author
Jens Axboe
<axboe@fb.com>
Wed, 9 Apr 2014 03:15:09 +0000
(21:15 -0600)
committer
Jens Axboe
<axboe@fb.com>
Wed, 9 Apr 2014 03:15:09 +0000
(21:15 -0600)
Signed-off-by: Jens Axboe <axboe@fb.com>
diskutil.c
patch
|
blob
|
blame
|
history
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;