From: Ged Murphy Date: Thu, 24 Nov 2005 00:21:42 +0000 (+0000) Subject: only display host info once when more than one adapter is present. X-Git-Tag: backups/ros-branch-0_2_9@19949~419 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=14e1f7b936c11103e5a6c0b2e77e0f1b3dfc24fe;ds=inline only display host info once when more than one adapter is present. svn path=/trunk/; revision=19509 --- diff --git a/reactos/apps/utils/net/ipconfig/ipconfig.c b/reactos/apps/utils/net/ipconfig/ipconfig.c index 776d31c9827..1eaa5b95696 100644 --- a/reactos/apps/utils/net/ipconfig/ipconfig.c +++ b/reactos/apps/utils/net/ipconfig/ipconfig.c @@ -149,23 +149,25 @@ INT ShowInfo(BOOL bAll) _tprintf(_T("\nReactOS IP Configuration\n\n")); + + if (bAll) + { + _tprintf(_T("\tHost Name . . . . . . . . . . . . : %s\n"), pFixedInfo->HostName); + _tprintf(_T("\tPrimary DNS Suffix. . . . . . . . : \n")); + _tprintf(_T("\tNode Type . . . . . . . . . . . . : %s\n"), GetNodeTypeName(pFixedInfo->NodeType)); + if (pFixedInfo->EnableRouting) + _tprintf(_T("\tIP Routing Enabled. . . . . . . . : Yes\n")); + else + _tprintf(_T("\tIP Routing Enabled. . . . . . . . : No\n")); + if (pAdapter->HaveWins) + _tprintf(_T("\tWINS Proxy enabled. . . . . . . . : Yes\n")); + else + _tprintf(_T("\tWINS Proxy enabled. . . . . . . . : No\n")); + _tprintf(_T("\tDNS Suffix Search List. . . . . . : %s\n"), pFixedInfo->DomainName); + } + while (pAdapter) { - if (bAll) - { - _tprintf(_T("\tHost Name . . . . . . . . . . . . : %s\n"), pFixedInfo->HostName); - _tprintf(_T("\tPrimary DNS Suffix. . . . . . . . : \n")); - _tprintf(_T("\tNode Type . . . . . . . . . . . . : %s\n"), GetNodeTypeName(pFixedInfo->NodeType)); - if (pFixedInfo->EnableRouting) - _tprintf(_T("\tIP Routing Enabled. . . . . . . . : Yes\n")); - else - _tprintf(_T("\tIP Routing Enabled. . . . . . . . : No\n")); - if (pAdapter->HaveWins) - _tprintf(_T("\tWINS Proxy enabled. . . . . . . . : Yes\n")); - else - _tprintf(_T("\tWINS Proxy enabled. . . . . . . . : No\n")); - _tprintf(_T("\tDNS Suffix Search List. . . . . . : %s\n"), pFixedInfo->DomainName); - } _tprintf(_T("\n%s ...... : \n\n"), GetInterfaceTypeName(pAdapter->Type));