meta: fix newline handling

This commit is contained in:
Stanislav Seletskiy 2019-08-13 19:48:11 +03:00
parent eb9f094a2d
commit ecee64f778
No known key found for this signature in database
GPG Key ID: E6B40F71C367E6B5

View File

@ -45,7 +45,7 @@ func ExtractMeta(data []byte) (*Meta, []byte, error) {
return nil, nil, err
}
offset += len(line)
offset += len(line) + 1
matches := reHeaderPatternV2.FindStringSubmatch(line)
if matches == nil {
@ -119,5 +119,5 @@ func ExtractMeta(data []byte) (*Meta, []byte, error) {
)
}
return meta, data[offset+1:], nil
return meta, data[offset:], nil
}