Avoid calling usbg_read_string() with a 40 byte long buffer, which in turn is filled in
by usbg_read_buf() which uses a maximum of 256 bytes (USBG_MAX_STR_LENGTH). This adjusts
the buffer to be the right size.
Signed-off-by: Philippe De Swert <philippe.deswert@jollamobile.com>
[Port from libusbg and update description]
Signed-off-by: Krzysztof Opasiak <k.opasiak@samsung.com>
usbg_function_attrs *f_attrs)
{
struct ether_addr *addr;
- char str_addr[40];
+ char str_addr[USBG_MAX_STR_LENGTH];
int ret;
ret = usbg_read_string(f->path, f->name, "dev_addr", str_addr);