Skip to content

Commit afbc922

Browse files
committed
[NETCFGX] Fix the output of ITcpipProperties_fnUnknown1
- An empty parameter must be returned as an empty string instead of '(null)'. - Add missing parameters DynamicUpdate and NameRegistration.
1 parent 2ec7c03 commit afbc922

1 file changed

Lines changed: 10 additions & 5 deletions

File tree

‎dll/win32/netcfgx/tcpipconf_notify.c‎

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -477,11 +477,13 @@ BuildParametersString(
477477
TRACE("Name Servers %S\n", pszNameServers);
478478

479479
/* Get the Parameters string length */
480-
nLength = _scwprintf(L"DefGw=%s;GwMetric=%s;IfMetric=%lu;DNS=%s;",
480+
nLength = _scwprintf(L"DefGw=%s;GwMetric=%s;IfMetric=%lu;DNS=%s;DynamicUpdate=%lu;NameRegistration=%lu;",
481481
pszDefGateway ? pszDefGateway : L"",
482482
pszGatewayMetric ? pszGatewayMetric : L"",
483483
pAdapter->NewMetric,
484-
pszNameServers ? pszNameServers : L"");
484+
pszNameServers ? pszNameServers : L"",
485+
pAdapter->NewRegisterAdapterName ? 1 : 0,
486+
pAdapter->NewRegistrationEnabled ? 1 : 0);
485487

486488
TRACE("Param string length %d\n", nLength);
487489
if (nLength == -1)
@@ -499,11 +501,13 @@ BuildParametersString(
499501

500502
/* Fill the Parameters buffer */
501503
_swprintf(pszParameters,
502-
L"DefGw=%s;GwMetric=%s;IfMetric=%lu;DNS=%s;",
504+
L"DefGw=%s;GwMetric=%s;IfMetric=%lu;DNS=%s;DynamicUpdate=%lu;NameRegistration=%lu;",
503505
pszDefGateway ? pszDefGateway : L"",
504506
pszGatewayMetric ? pszGatewayMetric : L"",
505507
pAdapter->NewMetric,
506-
pszNameServers ? pszNameServers : L"");
508+
pszNameServers ? pszNameServers : L"",
509+
pAdapter->NewRegisterAdapterName ? 1 : 0,
510+
pAdapter->NewRegistrationEnabled ? 1 : 0);
507511

508512
TRACE("Parameters %S\n", pszParameters);
509513

@@ -4623,7 +4627,7 @@ ITcpipProperties_fnUnknown1(
46234627
DWORD dwSize;
46244628
HRESULT hr = S_OK;
46254629

4626-
ERR("ITcpipProperties_fnUnknown1(%s %p)\n", wine_dbgstr_guid(pAdapterName), ppProperties);
4630+
TRACE("ITcpipProperties_fnUnknown1(%s %p)\n", wine_dbgstr_guid(pAdapterName), ppProperties);
46274631
TcpipConfNotifyImpl *This = impl_from_ITcpipProperties(iface);
46284632

46294633
pAdapter = GetAdapterByGuid(This, pAdapterName);
@@ -4635,6 +4639,7 @@ ITcpipProperties_fnUnknown1(
46354639
if (FAILED(hr))
46364640
goto done;
46374641

4642+
TRACE("DHCP: %lu\n", pAdapter->NewDhcpEnabled);
46384643
TRACE("IpAddress string: %S\n", pszIpAddress);
46394644

46404645
/* Build the Parameters string */

0 commit comments

Comments
 (0)