Skip to content

Commit

Permalink
Mkae clippy happy
Browse files Browse the repository at this point in the history
  • Loading branch information
Konstantin Knizhnik committed Dec 17, 2024
1 parent 52757cc commit 6be9c67
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions libs/postgres_ffi/src/xlog_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,6 @@ pub fn generate_pg_control(
) -> anyhow::Result<(Bytes, u64, bool)> {
let mut pg_control = ControlFileData::decode(pg_control_bytes)?;
let mut checkpoint = CheckPoint::decode(checkpoint_bytes)?;
let was_shutdown;

// Generate new pg_control needed for bootstrap
//
Expand All @@ -166,7 +165,7 @@ pub fn generate_pg_control(
// always set to the LSN we're starting at, to hint that no WAL replay is required.
// (There's some neon-specific code in Postgres startup to make that work, though.
// Just setting the redo pointer is not sufficient.)
was_shutdown = Lsn(checkpoint.redo) == lsn;
let was_shutdown = Lsn(checkpoint.redo) == lsn;
checkpoint.redo = normalize_lsn(lsn, WAL_SEGMENT_SIZE).0;

// We use DBState_DB_SHUTDOWNED even if it was not a clean shutdown. The
Expand Down

0 comments on commit 6be9c67

Please sign in to comment.