mirror of
https://github.com/Luzifer/sii.git
synced 2024-12-21 00:21:15 +00:00
Spare a little CPU resources
Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
8b43a5d38e
commit
2167e6ffa7
1 changed files with 1 additions and 1 deletions
|
@ -67,7 +67,7 @@ func ParseSIIPlainFile(r io.Reader) (*Unit, error) {
|
||||||
|
|
||||||
return nil, errors.New("Unexpected closing braces")
|
return nil, errors.New("Unexpected closing braces")
|
||||||
|
|
||||||
case blockStartRegex.MatchString(line) && !inBlock:
|
case !inBlock && blockStartRegex.MatchString(line):
|
||||||
if !inUnit {
|
if !inUnit {
|
||||||
return nil, errors.New("Unexpected block start outside unit")
|
return nil, errors.New("Unexpected block start outside unit")
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue