acpid: fix extra closing brace in getdents match
In drivers/acpid/src/scheme.rs, the getdents function's match on HandleKind has 8 arm-close braces for 8 arms, but the source had 9 closing braces (the 9th at line 669 was extra, indented differently from the match opener at line 538). Rust's parser couldn't match them up: error: unexpected closing delimiter: '}' note: this delimiter might not be properly closed... note: ...as it matches this but it has different indentation The extra brace was at line 669, immediately after the HandleKind::ProcFile | DmiDir arm body, before the '_' wildcard. Removing it (so the 8 arm-closes match the 8 arms) makes the match block close cleanly. The match block now closes at the proper 8-space indent, matching the 'match' keyword. This is a pre-existing bug in the Phase II.X.W commit 'dcd70a1 acpid: Phase II.X.W S3 wake handling + kstop_enter_s3 helper'. The brace was probably added by mistake during one of the Phase II.X.W edits. The Phase II.X.W build was presumably tested on hardware that didn't exercise the getdents path that triggers this brace mismatch. Discovered when the redbear-mini build started exercising the acpid getdents path. Fix: delete the extra brace.
This commit is contained in:
Generated
+4
@@ -2952,3 +2952,7 @@ name = "zmij"
|
|||||||
version = "1.0.21"
|
version = "1.0.21"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa"
|
checksum = "b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa"
|
||||||
|
|
||||||
|
[[patch.unused]]
|
||||||
|
name = "libredox"
|
||||||
|
version = "0.1.18"
|
||||||
|
|||||||
@@ -666,7 +666,6 @@ impl SchemeSync for AcpiScheme<'_, '_> {
|
|||||||
// No children; reads/writes go through the
|
// No children; reads/writes go through the
|
||||||
// HandleKind match in kread/kwriteoff.
|
// HandleKind match in kread/kwriteoff.
|
||||||
}
|
}
|
||||||
}
|
|
||||||
_ => return Err(Error::new(EIO)),
|
_ => return Err(Error::new(EIO)),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user