]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
crushtool: do not dump core with non-unique bucket IDs
authorDavid Zafman <david.zafman@inktank.com>
Mon, 9 Sep 2013 20:01:12 +0000 (13:01 -0700)
committerSage Weil <sage@inktank.com>
Tue, 24 Sep 2013 16:03:58 +0000 (09:03 -0700)
commitfb15040b6cec6221baa550ddfffade823f784c4a
treee894b851ab671fced48a585845c4d6ddacbe0ef6
parent410db3f30c6eb54b807908c1f251ad4026e7d446
crushtool: do not dump core with non-unique bucket IDs

Return -EEXIST on duplicate ID
BUG FIX: crush_add_bucket() mixes error returns and IDs
  Add optional argument to return generated ID

Fixes: #6246
Signed-off-by: David Zafman <david.zafman@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 8c76f3a0f9cf100ea2c941dc2b61c470aa5033d7)
src/crush/CrushCompiler.cc
src/crush/CrushWrapper.cc
src/crush/CrushWrapper.h
src/crush/builder.c
src/crush/builder.h
src/crushtool.cc
src/mon/OSDMonitor.cc
src/osd/OSDMap.cc