Skip to content

Commit c472cf4

Browse files
committed
CBD-6348: [BP] clang-tidy: used after it was moved [bugprone-use-after-move]
Change-Id: I8977a2b3dcd64ae50f5f018faf29add363ddee17 Reviewed-on: https://review.couchbase.org/c/kv_engine/+/234818 Well-Formed: Restriction Checker Reviewed-by: Pavlos Georgiou <[email protected]> Tested-by: Trond Norbye <[email protected]>
1 parent 80d8dff commit c472cf4

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

engines/ep/src/ep_engine.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4255,7 +4255,7 @@ struct ConnPerStreamStatBuilder {
42554255
ConnPerStreamStatBuilder(DcpStatsOptions options)
42564256
: options(std::move(options)) {
42574257
// The stream stats format is required to emit stream stats.
4258-
Expects(options.getStreamStatsFormat().has_value());
4258+
Expects(this->options.getStreamStatsFormat().has_value());
42594259
}
42604260

42614261
/**

protocol/connection/client_mcbp_commands.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2103,10 +2103,10 @@ BinprotReturnMetaCommand::BinprotReturnMetaCommand(
21032103
cb::mcbp::ClientOpcode::ReturnMeta, d.info.id, d.value),
21042104
doc(std::move(d)) {
21052105
extras.setMutationType(type);
2106-
extras.setExpiration(d.info.expiration);
2107-
extras.setFlags(d.info.flags);
2108-
setCas(d.info.cas);
2109-
setDatatype(d.info.datatype);
2106+
extras.setExpiration(doc.info.expiration);
2107+
extras.setFlags(doc.info.flags);
2108+
setCas(doc.info.cas);
2109+
setDatatype(doc.info.datatype);
21102110
}
21112111

21122112
void BinprotReturnMetaCommand::encode(std::vector<uint8_t>& buf) const {

statistics/statdef.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ StatDef::StatDef(CBStatsKey cbstatsKey,
2727
type(type),
2828
labels(std::move(labels)) {
2929
if (metricFamily.empty()) {
30-
metricFamily = std::string(cbstatsKey);
30+
metricFamily = std::string(this->cbstatsKey);
3131
}
3232
metricFamily += unit.getSuffix();
3333
}

0 commit comments

Comments
 (0)