Fix panic in logparser if file cannot be opened (#3055)

This commit is contained in:
Daniel Nelson
2017-07-25 17:08:03 -07:00
committed by GitHub
parent 83f575fcea
commit a26fc52181

View File

@@ -182,7 +182,10 @@ func (l *LogParserPlugin) tailNewfiles(fromBeginning bool) error {
Location: &seek,
MustExist: true,
})
l.acc.AddError(err)
if err != nil {
l.acc.AddError(err)
continue
}
// create a goroutine for each "tailer"
l.wg.Add(1)