]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rbd: remove unnecessary condition
authorJosh Durgin <josh.durgin@dreamhost.com>
Fri, 21 Oct 2011 21:13:25 +0000 (14:13 -0700)
committerJosh Durgin <josh.durgin@dreamhost.com>
Mon, 24 Oct 2011 22:32:47 +0000 (15:32 -0700)
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
src/rbd.cc

index 63d4380c10b307c39070034b0eae82ace085da89..d01c3e42b2ed7ec738a42fe07be1cddb05f09a3d 100644 (file)
@@ -1069,7 +1069,7 @@ int main(int argc, const char **argv)
   if (snapname && talk_to_cluster &&
       (opt_cmd == OPT_INFO || opt_cmd == OPT_EXPORT || opt_cmd == OPT_COPY)) {
     r = image.snap_set(snapname);
-    if (r < 0 && !(r == -ENOENT && opt_cmd == OPT_SNAP_CREATE)) {
+    if (r < 0) {
       cerr << "error setting snapshot context: " << cpp_strerror(-r) << std::endl;
       exit(1);
     }