nsiproxy: Allow the name length to be IFNAMSIZ - 1.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52214
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Huw Davies 2021-12-23 07:25:19 +00:00 committed by Alexandre Julliard
parent 9156e124f3
commit 65f04bcc97
1 changed files with 1 additions and 1 deletions

View File

@ -259,7 +259,7 @@ static struct if_entry *add_entry( DWORD index, char *name )
struct if_entry *entry;
int name_len = strlen( name );
if (name_len >= IFNAMSIZ - 1) return NULL;
if (name_len >= sizeof(entry->if_unix_name)) return NULL;
entry = malloc( sizeof(*entry) );
if (!entry) return NULL;