]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
cls/rbd/cls_rbd.cc: use !empty() instead of 'size() > 0'
authorDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Wed, 13 Feb 2013 15:49:53 +0000 (16:49 +0100)
committerGreg Farnum <greg@inktank.com>
Thu, 14 Feb 2013 18:27:38 +0000 (10:27 -0800)
commitc4f1c0799fd2fcc83346a0b8b3c3477750c4db7c
tree8e71ae616b570865854dda926fcd257c165c2cd6
parentfb811ecff83750586cdd7dfbd1d28eee7ead8e70
cls/rbd/cls_rbd.cc: use !empty() instead of 'size() > 0'

Use empty() since it should be prefered as it has, following the
standard, a constant time complexity regardless of the containter
type. The same is not guaranteed for size().

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
src/cls/rbd/cls_rbd.cc