From 3dd08bf0c6159e8629220b0582d68100ff9f3118 Mon Sep 17 00:00:00 2001 From: Ralph Castain Date: Mon, 13 Jun 2005 14:49:21 +0000 Subject: [PATCH] Fix another subscription in the OOB to be quiet until after trigger fires. This commit was SVN r6044. --- .../gpr_replica_del_index_fn.c | 25 ++++++++++++++++++- src/mca/oob/tcp/oob_tcp.c | 3 ++- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/src/mca/gpr/replica/functional_layer/gpr_replica_del_index_fn.c b/src/mca/gpr/replica/functional_layer/gpr_replica_del_index_fn.c index 0b2920010c..9efecfd931 100644 --- a/src/mca/gpr/replica/functional_layer/gpr_replica_del_index_fn.c +++ b/src/mca/gpr/replica/functional_layer/gpr_replica_del_index_fn.c @@ -41,13 +41,36 @@ int orte_gpr_replica_delete_entries_fn(orte_gpr_addr_mode_t addr_mode, #if 0 orte_gpr_replica_container_t **ptr; orte_gpr_replica_itagval_t **valptr; - int i, j; + orte_gpr_replica_addr_mode_t tok_mode; + size_t i, j, num_found; if (orte_gpr_replica_globals.debug) { ompi_output(0, "[%lu,%lu,%lu] replica_delete_object entered: segment %s", ORTE_NAME_ARGS(*(orte_process_info.my_name)), seg->name); } + /* initialize storage for actions taken */ + orte_pointer_array_clear(orte_gpr_replica_globals.acted_upon); + orte_gpr_replica_globals.num_acted_upon = 0; + + /* extract the token address mode */ + tok_mode = 0x004f & addr_mode; + if (0x00 == tok_mode) { /* default tokens addressing mode to AND */ + tok_mode = ORTE_GPR_REPLICA_AND; + } + + /* find the specified container(s) */ + if (ORTE_SUCCESS != (rc = orte_gpr_replica_find_containers(&num_found, seg, tok_mode, + token_itags, num_tokens))) { + ORTE_ERROR_LOG(rc); + return rc; + } + + if (NULL == token_itags && 0 == num_found) { /* wildcard tokens but nothing found */ + /* no ERROR_LOG entry created as this is not a system failure */ + return ORTE_ERR_NOT_FOUND; + } + /* if num_tokens == 0 and num_keys == 0, remove segment */ if (0 == num_tokens && 0 == num_keys) { return orte_gpr_replica_release_segment(seg); diff --git a/src/mca/oob/tcp/oob_tcp.c b/src/mca/oob/tcp/oob_tcp.c index 6f40dc9367..e811e005bb 100644 --- a/src/mca/oob/tcp/oob_tcp.c +++ b/src/mca/oob/tcp/oob_tcp.c @@ -850,7 +850,8 @@ int mca_oob_tcp_init(void) subs = ⊂ rc = orte_gpr.subscribe( ORTE_GPR_NOTIFY_ADD_ENTRY | ORTE_GPR_NOTIFY_VALUE_CHG | - ORTE_GPR_TRIG_CMP_LEVELS | ORTE_GPR_TRIG_ONE_SHOT, + ORTE_GPR_TRIG_CMP_LEVELS | ORTE_GPR_TRIG_ONE_SHOT | + ORTE_GPR_NOTIFY_STARTS_AFTER_TRIG, 1, &subs, 1, &trigs, &subscription->subid);