rbd: fix image id leak in initial probe
authorAlex Elder <elder@inktank.com>
Fri, 26 Apr 2013 04:15:08 +0000 (23:15 -0500)
committerSage Weil <sage@inktank.com>
Thu, 2 May 2013 04:19:34 +0000 (21:19 -0700)
commit5655c4d940ba8dd32250ab1e4ba3db785943a28e
treeeca7458b04f89420efe1fdfe576488f9cd6814b9
parentc0fba36880288afbeca872298c970fb4abb76464
rbd: fix image id leak in initial probe

If a format 2 image id is found for an image being mapped, but the
subsequent probe of the image fails, rbd_dev_probe() quits without
freeing the image id.  Fix that.

Also drop a redundant hunk of code in rbd_dev_image_id().

Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
drivers/block/rbd.c