use max scan token size to hold large objects
This commit is contained in:
parent
6ed3ec0cb3
commit
9c7f30d31c
1 changed files with 1 additions and 0 deletions
|
@ -24,6 +24,7 @@ func Parse(reader io.Reader) ([]Command, error) {
|
||||||
var command, modelCommand Command
|
var command, modelCommand Command
|
||||||
|
|
||||||
scanner := bufio.NewScanner(reader)
|
scanner := bufio.NewScanner(reader)
|
||||||
|
scanner.Buffer(make([]byte, 0, bufio.MaxScanTokenSize), bufio.MaxScanTokenSize)
|
||||||
scanner.Split(scanModelfile)
|
scanner.Split(scanModelfile)
|
||||||
for scanner.Scan() {
|
for scanner.Scan() {
|
||||||
line := scanner.Bytes()
|
line := scanner.Bytes()
|
||||||
|
|
Loading…
Reference in a new issue