From 1fabd2b1a43537d5efc099cd2b20dbe158456fcc Mon Sep 17 00:00:00 2001 From: Amaresh Kumar Date: Fri, 7 Sep 2018 10:51:39 +0530 Subject: Fixed Blocker issue in DRRouterCLI.java https://sonar.onap.org/project/issues?id=org.onap.dmaap.datarouter%3Aparent&open=AWHFaQoPEU5FCDfKtnWE&resolved=false&severities=BLOCKER&types=BUG Issue-ID: DMAAP-720 Change-Id: I450ec9604fd5fa4f4c9f21a275f9de94ccc6ad09 Signed-off-by: Amaresh Kumar --- .../org/onap/dmaap/datarouter/provisioning/utils/DRRouteCLI.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/utils/DRRouteCLI.java b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/utils/DRRouteCLI.java index 1bbf4460..af8bd6d3 100644 --- a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/utils/DRRouteCLI.java +++ b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/utils/DRRouteCLI.java @@ -339,8 +339,11 @@ public class DRRouteCLI { sb.append("Egress Routing Table\n"); sb.append(String.format("%s Node\n", ext("SubID", cw1))); for (int i = 0; i < subs.length; i++) { - String node = ert.getString(subs[i]); - sb.append(String.format("%s %s\n", ext(subs[i], cw1), node)); + if(ert!=null&&ert.length()!=0) { + String node = ert.getString(subs[i]); + sb.append(String.format("%s %s\n", ext(subs[i], cw1), node)); + } + } } if (tbl.startsWith("al") || tbl.startsWith("ne")) { -- cgit 1.2.3-korg