| 232 | } |
| 233 | |
| 234 | func (pool *CheckPool) recordCheckStat(bl *baseline.Baseline) { |
| 235 | if pool.Statistor == nil || bl == nil || bl.SprayResult == nil { |
| 236 | return |
| 237 | } |
| 238 | if pool.Statistor.Counts == nil { |
| 239 | pool.Statistor.Counts = make(map[int]int) |
| 240 | } |
| 241 | if pool.Statistor.Sources == nil { |
| 242 | pool.Statistor.Sources = make(map[parsers.SpraySource]int) |
| 243 | } |
| 244 | if bl.Status != 0 { |
| 245 | pool.Statistor.Counts[bl.Status]++ |
| 246 | } |
| 247 | if bl.Source.Name() != "" { |
| 248 | pool.Statistor.Sources[bl.Source]++ |
| 249 | } |
| 250 | if bl.IsValid { |
| 251 | pool.Statistor.FoundNumber++ |
| 252 | } |
| 253 | if bl.IsFuzzy { |
| 254 | pool.Statistor.FuzzyNumber++ |
| 255 | } |
| 256 | } |
| 257 | |
| 258 | func (pool *CheckPool) doRedirect(bl *baseline.Baseline, depth int) { |
| 259 | if depth >= pool.MaxRedirect { |