Don't repeat port GUIDs when more then one regular expression matches. Signed-off-by: Sasha Khapyorsky <sas...@voltaire.com> --- opensm/opensm/osm_console.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/opensm/opensm/osm_console.c b/opensm/opensm/osm_console.c index 0f26e51..0c3cdbf 100644 --- a/opensm/opensm/osm_console.c +++ b/opensm/opensm/osm_console.c @@ -1285,9 +1285,11 @@ static void dump_portguid_parse(char **p_last, osm_opensm_t * p_osm, FILE * out) p_regexp = p_regexp->next) if (regexec (&(p_regexp->exp), p_port->p_node->print_desc, 0, - NULL, 0) == 0) + NULL, 0) == 0) { fprintf(output, "0x%" PRIxLEAST64 "\n", cl_ntoh64(p_port->p_physp->port_guid)); + break; + } } CL_PLOCK_RELEASE(p_osm->sm.p_lock); -- 1.6.1.2.319.gbd9e _______________________________________________ general mailing list general@lists.openfabrics.org http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general