From 9abaf60008f909d1170331bdc979dca78096a437 Mon Sep 17 00:00:00 2001 From: Robbert van der Helm Date: Sun, 19 Jul 2020 19:08:01 +0200 Subject: [PATCH] Fix potential out of bounds error in Wine check --- tools/yabridgectl/src/utils.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/yabridgectl/src/utils.rs b/tools/yabridgectl/src/utils.rs index 9a487106..5e02b3ac 100644 --- a/tools/yabridgectl/src/utils.rs +++ b/tools/yabridgectl/src/utils.rs @@ -218,7 +218,7 @@ pub fn verify_wine_setup(config: &mut Config) -> Result<()> { // Ignore fixme messages here, since those can be produced by wineserver even after the // application has errored out - if &line[5..10] != "fixme" { + if line.get(5..10) != Some("fixme") { last_error = Some(line); } }