Skip to content

Commit

Permalink
Try different way of bailing out
Browse files Browse the repository at this point in the history
  • Loading branch information
boyter committed Sep 12, 2019
1 parent 1071695 commit e536c67
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
7 changes: 4 additions & 3 deletions processor/file.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ func (dw *DirectoryWalker) Readdir(handle *cuba.Handle) {

for _, dirent := range dirents {
if returnEarly() {
dw.buffer.SetReturnEarly(true)

dw.buffer.EmptyPool()
return
}

Expand All @@ -145,7 +146,7 @@ func (dw *DirectoryWalker) Readdir(handle *cuba.Handle) {
DIRENTS:
for _, dirent := range dirents {
if returnEarly() {
dw.buffer.SetReturnEarly(true)
dw.buffer.EmptyPool()
return
}

Expand Down Expand Up @@ -173,7 +174,7 @@ DIRENTS:

for _, ignore := range ignores {
if returnEarly() {
dw.buffer.SetReturnEarly(true)
dw.buffer.EmptyPool()
return
}

Expand Down
2 changes: 1 addition & 1 deletion processor/tui.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func debounce(interval time.Duration, input chan string, app *tview.Application,

func tuiSearch(app *tview.Application, textView *tview.TextView, searchTerm string) {
// Kill off anything else that's potentially still processing
//StopProcessing = true
StopProcessing = true
// Wait for background processes to die off
//routineWaitGroup.Wait()

Expand Down
9 changes: 4 additions & 5 deletions vendor/github.com/dbaggerman/cuba/pool.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit e536c67

Please sign in to comment.