4298a304e1649c6e64f554933a42b9cd02615338
The corosync.conf parser split the whole file into whitespace separated tokens and always took exactly one token as value. Values containing whitespace, like a manually set cluster_name "my cluster", are accepted by corosync, but made the parser fail with "missing ':' after key". Any API call reading the corosync config then failed, for example when adding an HA resource. Parse the file line by line instead, like corosync does, and take the rest of the line after the first ':' as value. Section headers and closing brackets still need to be on their own line, which corosync requires anyway. Add a test config with whitespace in the cluster name. Signed-off-by: Michal Fox <me@dualfroz.com>
Description
My contributions to proxmox-git/pve-cluster: 2 commits
54 KiB
0 Stars
1 Watchers
0 Forks
Languages
Perl
100%