mirror of
https://github.com/dogkeeper886/ollama37.git
synced 2025-12-10 15:57:04 +00:00
use max scan token size to hold large objects
This commit is contained in:
@@ -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()
|
||||||
|
|||||||
Reference in New Issue
Block a user