https://git.reactos.org/?p=reactos.git;a=commitdiff;h=1b35626d54ea157dbeb07…
commit 1b35626d54ea157dbeb07660dd2a8308e0facb16
Author: Eric Kohl <eric.kohl(a)reactos.org>
AuthorDate: Sun Oct 24 16:52:18 2021 +0200
Commit: Eric Kohl <eric.kohl(a)reactos.org>
CommitDate: Sun Oct 24 16:52:18 2021 +0200
[IPHLPAPI] GetInterfaceInfo(): Add "\DEVICE\TCPIP_"-Prefix to interface
names
---
dll/win32/iphlpapi/iphlpapi_main.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/dll/win32/iphlpapi/iphlpapi_main.c b/dll/win32/iphlpapi/iphlpapi_main.c
index 7a4253ff65d..377a1cbaa80 100644
--- a/dll/win32/iphlpapi/iphlpapi_main.c
+++ b/dll/win32/iphlpapi/iphlpapi_main.c
@@ -1763,9 +1763,10 @@ DWORD WINAPI GetInterfaceInfo(PIP_INTERFACE_INFO pIfTable, PULONG
dwOutBufLen)
pIfTable->Adapter[ndx].Index = table->indexes[ndx];
name = getInterfaceNameByIndex(table->indexes[ndx]);
- for (walker = name, assigner = pIfTable->Adapter[ndx].Name;
+ wcscpy(pIfTable->Adapter[ndx].Name, L"\\DEVICE\\TCPIP_");
+ for (walker = name, assigner = &pIfTable->Adapter[ndx].Name[14];
walker && *walker &&
- assigner - pIfTable->Adapter[ndx].Name < MAX_ADAPTER_NAME - 1;
+ assigner - pIfTable->Adapter[ndx].Name < MAX_ADAPTER_NAME - 1 - 14;
walker++, assigner++)
*assigner = *walker;
*assigner = 0;