forge
Explore
Log in

Don't you dare go Hollow

Fix new Clippy warning

Browse files at this commit

cb5d97f600c7dc5bb31525c5cd664c1377145d87Ivan MolodetskikhParent: 608ab7d
This was stabilized in 1.76 so we can use it now.
src/backend/tty.rsmodified+1 -2
@@ -1949,14 +1949,13 @@ impl GammaProps {
1949 property::Value::Blob(blob).into(),1949 property::Value::Blob(blob).into(),
1950 )1950 )
1951 .context("error setting GAMMA_LUT")1951 .context("error setting GAMMA_LUT")
1952- .map_err(|err| {1952+ .inspect_err(|_| {
1953 if blob != 0 {1953 if blob != 0 {
1954 // Destroy the blob we just allocated.1954 // Destroy the blob we just allocated.
1955 if let Err(err) = device.destroy_property_blob(blob) {1955 if let Err(err) = device.destroy_property_blob(blob) {
1956 warn!("error destroying GAMMA_LUT property blob: {err:?}");1956 warn!("error destroying GAMMA_LUT property blob: {err:?}");
1957 }1957 }
1958 }1958 }
1959- err
1960 })?;1959 })?;
1961 }1960 }
1962 1961