]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
librbd: remove unused rbd_image_options_t ostream operator 15443/head
authorMykola Golub <mgolub@mirantis.com>
Sat, 3 Jun 2017 08:34:17 +0000 (10:34 +0200)
committerMykola Golub <mgolub@mirantis.com>
Sat, 3 Jun 2017 08:43:01 +0000 (10:43 +0200)
This fixes librbd crashes currently observed on master, when
debug is on, because `rbd_image_options_t` is typedef-ed `void *`
and it's operator is used when attempting to print out an
address (`void *`) of any object.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
src/librbd/internal.cc

index 00606fcd2e6d81c5b12bc3a021629e81e0586fdc..40931127bd1ac3785bc08b78d51f7da1c393dec6 100644 (file)
@@ -327,22 +327,6 @@ int validate_pool(IoCtx &io_ctx, CephContext *cct) {
     }
   }
 
-  std::ostream &operator<<(std::ostream &os, const rbd_image_options_t &opts) {
-    image_options_ref* opts_ = static_cast<image_options_ref*>(opts);
-
-    os << "[";
-
-    for (image_options_t::const_iterator i = (*opts_)->begin();
-        i != (*opts_)->end(); ++i) {
-      os << (i == (*opts_)->begin() ? "" : ", ") << image_option_name(i->first)
-        << "=" << i->second;
-    }
-
-    os << "]";
-
-    return os;
-  }
-
   std::ostream &operator<<(std::ostream &os, const ImageOptions &opts) {
     os << "[";