Merge pull request #976 from golangci/increase-scanner-buffer
autogenerated_exclude: increase scanner max buffer size
This commit is contained in:
commit
c9ff1ae80d
@ -124,7 +124,7 @@ func getDoc(filePath string) (string, error) {
|
||||
// Issue 954: Some lines can be very long, e.g. auto-generated
|
||||
// embedded resources. Reported on file of 86.2KB.
|
||||
const (
|
||||
maxSize = 512 * 1024 // 512KB should be enough
|
||||
maxSize = 10 * 1024 * 1024 // 10MB should be enough
|
||||
initialSize = 4096 // same as startBufSize in bufio
|
||||
)
|
||||
scanner.Buffer(make([]byte, initialSize), maxSize)
|
||||
|
Loading…
x
Reference in New Issue
Block a user