Skip to content

Commit b007590

Browse files
Randall FlaggRandall Flagg
authored andcommitted
Fixed CR issues
1 parent fe05430 commit b007590

4 files changed

Lines changed: 3 additions & 9 deletions

File tree

src/LogExpert.Core/Classes/Filter/FilterPipe.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ public void CloseFile ()
7272
}
7373
}
7474

75+
//TOOD: check if the callers are checking for null before calling
7576
public bool WriteToPipe (ILogLine textLine, int orgLineNum)
7677
{
7778
ArgumentNullException.ThrowIfNull(textLine, nameof(textLine));

src/LogExpert.Core/Classes/Filter/FilterStarter.cs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@ public async void DoFilter (FilterParams filterParams, int startLine, int maxCou
8585
}
8686

8787
var workStartLine = startLine;
88-
List<WaitHandle> handleList = [];
8988
_progressLineCount = 0;
9089
_progressCallback = progressCallback;
9190
while (workStartLine < startLine + maxCount)
@@ -105,13 +104,6 @@ public async void DoFilter (FilterParams filterParams, int startLine, int maxCou
105104
workStartLine += interval;
106105
}
107106

108-
WaitHandle[] handles = [.. handleList];
109-
// wait for worker threads completion
110-
if (handles.Length > 0)
111-
{
112-
_ = WaitHandle.WaitAll(handles);
113-
}
114-
115107
MergeResults();
116108
}
117109

src/LogExpert.Core/Classes/Util.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ public static string GetFileSizeAsText (long size)
6161
: string.Empty + $"{size / 1048576.0:0.00}" + " MB";
6262
}
6363

64+
//TOOD: check if the callers are checking for null before calling
6465
public static bool TestFilterCondition (FilterParams filterParams, ILogLine line, ILogLineColumnizerCallback columnizerCallback)
6566
{
6667
ArgumentNullException.ThrowIfNull(filterParams, nameof(filterParams));

src/LogExpert.UI/Controls/LogWindow/LogWindowPrivate.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -800,7 +800,7 @@ private void CheckFilterAndHighlight (LogEventArgs e)
800800
for (var i = filterStart; i < e.LineCount; ++i)
801801
{
802802
var line = _logFileReader.GetLogLine(i);
803-
//TODO: Why line can equal null here? Prevent this from happening and replace the check with an exception throw
803+
//TODO: Why line can be equal null here? Need to understand all the situations and handle them correctlly. Prevent this from happening and replace the check with an exception throw
804804
if (line == null)
805805
{
806806
return;

0 commit comments

Comments
 (0)