]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
common: pick_addresses: fix bug with observer class that triggered #5205
authorJoao Eduardo Luis <joao.luis@inktank.com>
Fri, 9 Aug 2013 21:48:15 +0000 (14:48 -0700)
committerJoao Eduardo Luis <joao.luis@inktank.com>
Fri, 9 Aug 2013 21:48:15 +0000 (14:48 -0700)
commit7ed6de9dd7aed59f3c5dd93e012cf080bcc36d8a
tree571e2547cab6054f0aee0c1d700c9dc742c87efb
parent068baae719b6a06487110e30b3cdcafddda0e579
common: pick_addresses: fix bug with observer class that triggered #5205

The Observer class we defined to observe conf changes and thus avoid
triggering #5205 (as fixed by eb86eebe1ba42f04b46f7c3e3419b83eb6fe7f9a),
was returning always the same const static array, which would lead us to
always populate the observer's list with an observer for 'public_addr'.

This would of course become a problem when trying to obtain the observer
for 'cluster_add' during md_config_t::set_val() -- thus triggering the
same assert as initially reported on #5205.

Backport: cuttlefish
Fixes: #5205
Signed-off-by: Joao Eduardo Luis <jecluis@gmail.com>
Reviewed-by: Sage Weil <sage@inktank.com>
src/common/pick_address.cc