Commit 969238b1 authored by Michael Yang's avatar Michael Yang
Browse files

fix padding in decode

TODO: update padding() to _only_ returning the padding
parent 0efb7931
...@@ -243,7 +243,7 @@ func (llm *gguf) Decode(rs io.ReadSeeker) error { ...@@ -243,7 +243,7 @@ func (llm *gguf) Decode(rs io.ReadSeeker) error {
} }
padding := llm.padding(offset, int64(alignment)) padding := llm.padding(offset, int64(alignment))
if _, err := rs.Seek(padding, io.SeekCurrent); err != nil { if _, err := rs.Seek(padding-offset, io.SeekCurrent); err != nil {
return err return err
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment