Problem with generic call completion

i’ve setup call completion with example provided as following link

wiki.asterisk.org/wiki/display/ … on+Example

[code]
sip.conf
[Mark]
context=phone_calls
cc_agent_policy=generic
cc_monitor_policy=generic ;We will accept defaults for the rest of the cc parameters
;We also are not concerned with other SIP details for this
;example

[Richard]
context=phone_calls
cc_agent_policy=generic
cc_monitor_policy=generic[/code]

extensions.conf
[phone_calls]
exten => 1000,1,Dial(SIP/Mark,20)
exten => 1000,n,Hangup
exten => 2000,1,Dial(SIP/Richard,20)
exten => 2000,n,Hangup
exten => 30,1,CallCompletionRequest
exten => 30,n,Hangup
exten => 31,1,CallCompletionCancel
exten => 31,n,Hangup

IN Scenario 2: Richard picks up his phone and dials Mark by dialing 1000. Mark has stepped away from his desk, and so he is unable to answer the phone within the 20 second dial timeout. Richard hangs up, picks the phone back up and then dials 30 to request call completion. Mark gets back to his desk and dials somebody’s number. When Mark finishes the call, Asterisk detects that Mark’s phone has had some activity and has become available again and rings Richard’s phone. Once Richard picks up, Asterisk automatically dials exteision 1000 for him.

Problem is when Mark gets back to his desk and dial to Richard phone (its natural cause Mark found a miss call from Richard in his phone) and finish talkings with Richard , Richard gets the ring from CC and they both get connected again , though they finished their talking.

any solution … ?