git-mirror
git-mirror copied to clipboard
Syntax error causes config parser to go into infinite loop
I noticed when I had a config file with
[[ Repo ]]
instead of
[[Repo]]
git-mirror just hung and consumed 100% cpu when starting with no message printed to stderr/out. A bit of debugging turned out that the culprit was the toml parser which went into an infinite loop.
Perhaps switch to another toml parser, https://github.com/toml-lang/toml lists several ones for golang.
Hi @jabl, thanks for the report, I'll confirm it's coming from the TOML parser and see if we can fix it upstream or look at changing libraries.