]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
crush/builder: prevent bucket weight underflow on item removal
authorSage Weil <sage@redhat.com>
Sat, 22 Nov 2014 01:47:56 +0000 (17:47 -0800)
committerLoic Dachary <ldachary@redhat.com>
Mon, 15 Dec 2014 09:26:42 +0000 (10:26 +0100)
commitcee51af9c1dbde550177c95caf6c93f612442300
tree920beb9abec2848ec6cb513794dad44da0b310a1
parent7ccd5eec11e8cd945d24bf9f6390d6c3fa4a06de
crush/builder: prevent bucket weight underflow on item removal

It is possible to set a bucket weight that is not the sum of the item
weights if you manually modify/build the CRUSH map.  Protect against any
underflow on the bucket weight when removing items.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 8c87e9502142d5b4a282b94f929ae776a49be1dc)
src/crush/builder.c