diff options
author | mrb0nk500 <b0nk@b0nk.xyz> | 2022-08-01 12:29:22 -0300 |
---|---|---|
committer | mrb0nk500 <b0nk@b0nk.xyz> | 2022-08-01 12:31:40 -0300 |
commit | 5589b9898b0bd9bbdfdf3c78c532e9bb104d5c41 (patch) | |
tree | 2e4276c410d9dbff9d5433b30d4f1ca68a356dce | |
parent | 262a5fa99b1a807050bcaf592a533b30107af6be (diff) |
keyword: Remove trailing whitespace from the right hand side in
`parse_key_value_file()`
-rw-r--r-- | keyword.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -115,6 +115,8 @@ int parse_key_value_file(void *ret, void *ctx, const keyword **keywords, char *b } else { /* Get the rest of the line. */ rhs = strtok_r(tmp, "\n", &buf); + /* Remove any whitespace ahead of us. */ + rhs = strtok_r(rhs, " \t\v\r\n", &tmp); } /* Did we fail to parse the keyword? */ |