Fix for buffer overflow defect.

Array index of 'path' may be out of bounds. Array
'path' of size 256 may use index value(s) 0..284.

Signed-off-by: Artur Wojcik <artur.wojcik@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
This commit is contained in:
Artur Wojcik 2009-12-10 12:03:40 -07:00 committed by Dan Williams
parent 37f0e1e025
commit 5dbb8c8d76
1 changed files with 1 additions and 1 deletions

View File

@ -44,7 +44,7 @@ void free_sys_dev(struct sys_dev **list)
struct sys_dev *find_driver_devices(const char *bus, const char *driver)
{
/* search sysfs for devices driven by 'driver' */
char path[256];
char path[292];
char link[256];
char *c;
DIR *driver_dir;