aboutsummaryrefslogtreecommitdiff
path: root/utils.c
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2020-09-14 01:21:49 -0700
committerBruce Hill <bruce@bruce-hill.com>2020-09-14 01:21:49 -0700
commita82164505e89dc8257ef87844dfef1476e235a7f (patch)
treef545e4a76b0ff0472bf6046b951230672ad18ce4 /utils.c
parent9f2d5464d6fd2c2aeb6dc234c64bd3aafe22d6e0 (diff)
Added nodent support (|)
Diffstat (limited to 'utils.c')
-rw-r--r--utils.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/utils.c b/utils.c
index 5078c01..7844934 100644
--- a/utils.c
+++ b/utils.c
@@ -46,9 +46,9 @@ const char *after_name(const char *str)
*/
int matchchar(const char **str, char c)
{
- *str = after_spaces(*str);
- if (**str == c) {
- ++(*str);
+ const char *next = after_spaces(*str);
+ if (*next == c) {
+ *str = &next[1];
return 1;
} else {
return 0;