From c716b2afbf181aa702d41946e5d105fd591fe13b Mon Sep 17 00:00:00 2001 From: Patrick LeBlanc Date: Mon, 4 Mar 2019 10:35:59 -0600 Subject: [PATCH] Tentative fix for the getsystemnetworkconfig cmd re mcol-1607. --- oamapps/mcsadmin/mcsadmin.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/oamapps/mcsadmin/mcsadmin.cpp b/oamapps/mcsadmin/mcsadmin.cpp index 362fb4b00..d07c67ffb 100644 --- a/oamapps/mcsadmin/mcsadmin.cpp +++ b/oamapps/mcsadmin/mcsadmin.cpp @@ -5404,7 +5404,14 @@ int processCommand(string* arguments) for ( ; pt1 != (*pt).hostConfigList.end() ; pt1++) { - string ipAddr = (*pt1).IPAddr; + /* MCOL-1607. IPAddr may be a host name here b/c it is read straight + from the config file. */ + string tmphost = oam.getIPAddress(pt1->IPAddr); + string ipAddr; + if (tmphost.empty()) + ipAddr = pt1->IPAddr; + else + ipAddr = tmphost; string hostname = (*pt1).HostName; string nicID = oam.itoa((*pt1).NicID);