Hi Neel,
Ok.
The nano-optimization was actually a correction to make the patch
effective :-)
/AndersBj
Neelakanta Reddy wrote:
> Hi Anders,
>
> Just realized, there is a problem in below patch.
>
> The problem with the floated patch is in
> ImmModel::discardImplementer, the value passed for reallyDiscard is
> false for immnd_proc_imma_discard_connection which is used at the time
> of Oifinalize . Because of this info->mDying is set to true.
>
>
> The patch should have been:
>
>
> diff --git a/osaf/services/saf/immsv/immnd/ImmModel.cc
> b/osaf/services/saf/immsv/immnd/ImmModel.cc
> --- a/osaf/services/saf/immsv/immnd/ImmModel.cc
> +++ b/osaf/services/saf/immsv/immnd/ImmModel.cc
> @@ -1508,6 +1508,7 @@ immModel_implIsFree(IMMND_CB *cb, const
> if(!impl) {return SA_AIS_OK;}
>
> if(impl->mId == 0) {return SA_AIS_OK;}
> + if(impl->mDying) {return SA_AIS_ERR_TRY_AGAIN;}
>
> return SA_AIS_ERR_EXIST;
> }
>
>
> /Neel.
>
>
> On Thursday 04 September 2014 05:37 PM, Anders Bjornerstedt wrote:
>> Ack from me with the nano-optimization suggested below
>>
>> [email protected] wrote:
>>> osaf/services/saf/immsv/immnd/ImmModel.cc | 1 +
>>> 1 files changed, 1 insertions(+), 0 deletions(-)
>>>
>>>
>>> At the time of OIfinalizing of the OI handle, An FEVS message is
>>> sent to clear the implementer. A FEVs message is sent from local
>>> IMMND to active IMMD and active IMMD broadcast the message to all
>>> IMMND. Before the broadcast FEVS message arrived from IMMD, the AMFD
>>> tries to set the implementer again with the same name and ERR_EXISTS
>>> is returned.
>>>
>>> if the implementer is not yet discarded and marked as not-dying
>>> (this is because the implementer set is arrived before clearing it
>>> in IMMNDs,) then TRY_AGAIN will be returned.
>>>
>>> diff --git a/osaf/services/saf/immsv/immnd/ImmModel.cc
>>> b/osaf/services/saf/immsv/immnd/ImmModel.cc
>>> --- a/osaf/services/saf/immsv/immnd/ImmModel.cc
>>> +++ b/osaf/services/saf/immsv/immnd/ImmModel.cc
>>> @@ -1508,6 +1508,7 @@ immModel_implIsFree(IMMND_CB *cb, const
>>> if(!impl) {return SA_AIS_OK;}
>>>
>>> if(impl->mId == 0) {return SA_AIS_OK;}
>>> + if(impl->mId && !impl->mDying) {return SA_AIS_ERR_TRY_AGAIN;
>> If impl->mId is zero then the previous if statement would have
>> returned OK from the function.
>> So this new if statement does not really need to check that impl->mId
>> is not zero.
>>
>> /AndersBj
>>>
>>> return SA_AIS_ERR_EXIST;
>>> }
>>
>
------------------------------------------------------------------------------
Slashdot TV.
Video for Nerds. Stuff that matters.
http://tv.slashdot.org/
_______________________________________________
Opensaf-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-devel