Skip to content

Commit

Permalink
fix regex
Browse files Browse the repository at this point in the history
  • Loading branch information
rounk-ctrl committed May 5, 2023
1 parent b42b361 commit f0bccc2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions QEMUWF/Core.cs
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,7 @@ public static void QemuInvoke(string cpu, ref List<string> value, string whiteli
while (!proc.StandardOutput.EndOfStream)
{
string line = proc.StandardOutput.ReadLine();
// fix the regex
const string reduceMultiSpace = @"\s+\s+\s+\s+.+";
const string reduceMultiSpace = @"(?<!^)\s{2}(?!$).+";
line = Regex.Replace(line, reduceMultiSpace, "");
if (!string.IsNullOrWhiteSpace(line) && line.Contains("Recognized CPUID flags:"))
{
Expand Down

0 comments on commit f0bccc2

Please sign in to comment.