Skip to contentSkip to conversation

openvpnmsica: remove adapter renaming

PATCH In review Lev Stipakov 3 participants 3 messages Sep 2, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 openvpnmsica: remove adapter renaming

From: Lev Stipakov <[email protected]...>

Renaming doesn't work on some machines (https://github.com/OpenVPN/openvpn-build/issues/187)
and we couldn't find the cause. Also others do not seem to do it, so let's get rid of it.

---
 src/openvpnmsica/openvpnmsica.c | 9 ---------
 1 file changed, 9 deletions(-)
src/openvpnmsica/openvpnmsica.c +0 -9
index 31e90bd2..10d4a1cc 100644
@@ -1094,15 +1094,6 @@ ProcessDeferredAction(_In_ MSIHANDLE hInstall)
 
             GUID guidAdapter;
             dwResult = tap_create_adapter(NULL, NULL, szHardwareId, &bRebootRequired, &guidAdapter);
-            if (dwResult == ERROR_SUCCESS)
-            {
-                /* Set adapter name. */
-                dwResult = tap_set_adapter_name(&guidAdapter, szName);
-                if (dwResult != ERROR_SUCCESS)
-                {
-                    tap_delete_adapter(NULL, &guidAdapter, &bRebootRequired);
-                }
-            }
         }
         else if (wcsncmp(szArg[i], L"deleteN=", 8) == 0)
         {
Signature · 1 line
2.17.1
#1 lore raw

Hi,

I would suggest to keep this renaming but make it not fatal. A descriptive name is nice to have and we could even make the name configurable at some point in future.

Selva

Quoted 45 lines · Lev Stipakov

From: Lev Stipakov <[email protected]...>

Renaming doesn't work on some machines (
https://github.com/OpenVPN/openvpn-build/issues/187)
and we couldn't find the cause. Also others do not seem to do it, so let's get rid of it.

---
 src/openvpnmsica/openvpnmsica.c | 9 ---------
 1 file changed, 9 deletions(-)
src/openvpnmsica/openvpnmsica.c +0 -9
index 31e90bd2..10d4a1cc 100644
@@ -1094,15 +1094,6 @@ ProcessDeferredAction(_In_ MSIHANDLE hInstall)
 
             GUID guidAdapter;
             dwResult = tap_create_adapter(NULL, NULL, szHardwareId,
 &bRebootRequired, &guidAdapter);
-            if (dwResult == ERROR_SUCCESS)
-            {
-                /* Set adapter name. */
-                dwResult = tap_set_adapter_name(&guidAdapter, szName);
-                if (dwResult != ERROR_SUCCESS)
-                {
-                    tap_delete_adapter(NULL, &guidAdapter,
 &bRebootRequired);
-                }
-            }
         }
         else if (wcsncmp(szArg[i], L"deleteN=", 8) == 0)
         {

--
2.17.1

_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

#2 lore raw

Hi,

Adapter name already is configurable in openvpn-build/windows-msi/msi.wxs: https://github.com/Amebis/openvpn-build/blob/5f5ba807de2bad50d01a5b08dfc6fad98ee41213/windows-msi/msi.wxs#L1300

Regards, Simon

From: Selva Nair <[email protected]...>
Sent: Wednesday, September 2, 2020 3:12 PM
To: Lev Stipakov <[email protected]...>
Cc: Lev Stipakov <[email protected]...>; openvpn-devel <[email protected]>
Subject: Re: [Openvpn-devel] [PATCH] openvpnmsica: remove adapter renaming

Hi,

I would suggest to keep this renaming but make it not fatal. A descriptive name is nice to have and we could even make the name configurable at some point in future.

Selva