diff --git a/src/fdb5/api/fdb_c.cc b/src/fdb5/api/fdb_c.cc index ce9589dad..c102108ee 100644 --- a/src/fdb5/api/fdb_c.cc +++ b/src/fdb5/api/fdb_c.cc @@ -100,7 +100,7 @@ struct fdb_split_key_t { } auto operator++() -> fdb_split_key_t& { - /// @todo the following "if" is an unfortuante consequense of a flaw in this iterator + /// @todo the following "if" is an unfortunate consequense of a flaw in this iterator if (level_ == keys_->end()) { level_ = keys_->begin(); curr_ = level_->begin(); @@ -127,7 +127,7 @@ struct fdb_split_key_t { *k = key.c_str(); *v = val.c_str(); - if (level) { *level = std::find(keys_->begin(), keys_->end(), *level_) - keys_->begin(); } + if (level) { *level = level_ - keys_->begin(); } } private: // members