wiphy: Reduce static allocation size

iwd_device_get_path() is not going to produce longer string than 12
bytes (/ + maximum of uint32_t expressed as a string + '\0').
This commit is contained in:
Tomasz Bursztyka 2015-02-26 13:03:05 +02:00 committed by Denis Kenzior
parent b067c08cfe
commit 6b018ca6f7
1 changed files with 1 additions and 1 deletions

View File

@ -319,7 +319,7 @@ static void network_free(void *data)
const char *iwd_device_get_path(struct netdev *netdev)
{
static char path[256];
static char path[12];
snprintf(path, sizeof(path), "/%u", netdev->index);
return path;