Skip to content

Commit

Permalink
修正多语句查询bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Becivells committed Dec 27, 2021
1 parent 24c821c commit 01a946c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions internal/runner/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -246,11 +246,11 @@ func (r *Runner) openURL(query string) {

func (r *Runner) Run() *sync.Map {
fo := fofa.NewFoFa(r.options)
for i := 0; i < r.query.Len(); i++ {
for r.query.Len() != 0 {
if !r.query.Any() {
break
}
fofaQuery := r.query.Peek()
fofaQuery := r.query.Pop()
// 提取完整的 hostInfo,带有 protocol -ffi
if r.options.FetchFullHostInfo {
fo.FetchFn = func(fields []string, allSize int32) bool {
Expand Down Expand Up @@ -292,7 +292,6 @@ func (r *Runner) Run() *sync.Map {
}
fo.Fetch(fofaQuery)
}
r.query.Pop()
}

return r.resMap
Expand Down

0 comments on commit 01a946c

Please sign in to comment.