MB-16915: Remove cyclic reference between DcpConsumer and PassiveStream. 29/57429/5
authorManu Dhundi <manu@couchbase.com>
Thu, 3 Dec 2015 21:32:35 +0000 (13:32 -0800)
committerManu Dhundi <manu@couchbase.com>
Thu, 3 Dec 2015 21:51:19 +0000 (21:51 +0000)
commit93d4b0fa5bcc154067d486c41ac59d21372162b3
treef1c26f522ba77668bc444f0a53d221a4a571f181
parent923a68c6a0a46d349b18cbadb62c37ab639e0a51
MB-16915: Remove cyclic reference between DcpConsumer and PassiveStream.

DcpConsumer holds a reference to PassiveStream and vice versa. We must
make sure that one of them (DcpConsumer here) releases the reference
to another in a function other than the object destructor.

Change-Id: I8e5c262bc5ac50342f85ba80d481987a26a7a21d
Reviewed-on: http://review.couchbase.org/57429
Reviewed-by: Chiyoung Seo <chiyoung@couchbase.com>
Tested-by: buildbot <build@couchbase.com>
src/dcp-consumer.cc
tests/ep_testsuite.cc