On 8/27/2018 9:48 PM, Honggang LI wrote: > From: Honggang Li <honli@xxxxxxxxxx> > > Issue was found by Coverity. > > Error: RESOURCE_LEAK (CWE-772): [#def12] > opensm-3.3.20/osmtest/osmt_service.c:988: alloc_fn: Storage is returned from allocation function "malloc". > opensm-3.3.20/osmtest/osmt_service.c:988: var_assign: Assigning: "p_checked_names" = storage returned from "malloc(1UL * num_of_valid_names)". > opensm-3.3.20/osmtest/osmt_service.c:1091: leaked_storage: Variable "p_checked_names" going out of scope leaks the storage it points to. > |# 1089| > |# 1090| OSM_LOG_EXIT(&p_osmt->log); > |# 1091|-> return status; > |# 1092| } > |# 1093| #endif > > Signed-off-by: Honggang Li <honli@xxxxxxxxxx> Thanks. Applied. -- Hal