mirror of
https://github.com/projectdiscovery/nuclei.git
synced 2025-12-24 04:55:29 +00:00
fix: race condition of the lastmatcherevent (#6080)
This commit is contained in:
parent
99f8df3fbd
commit
fa7329f16e
@ -215,8 +215,10 @@ func (e *TemplateExecuter) Execute(ctx *scan.ScanContext) (bool, error) {
|
|||||||
|
|
||||||
if lastMatcherEvent != nil {
|
if lastMatcherEvent != nil {
|
||||||
lastMatcherEvent.Lock()
|
lastMatcherEvent.Lock()
|
||||||
|
defer lastMatcherEvent.Unlock()
|
||||||
|
|
||||||
lastMatcherEvent.InternalEvent["error"] = getErrorCause(ctx.GenerateErrorMessage())
|
lastMatcherEvent.InternalEvent["error"] = getErrorCause(ctx.GenerateErrorMessage())
|
||||||
lastMatcherEvent.Unlock()
|
|
||||||
writeFailureCallback(lastMatcherEvent, e.options.Options.MatcherStatus)
|
writeFailureCallback(lastMatcherEvent, e.options.Options.MatcherStatus)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user