diff options
Diffstat (limited to 'c_src/tools-util.c')
-rw-r--r-- | c_src/tools-util.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/c_src/tools-util.c b/c_src/tools-util.c index 150925eb..a31adcb0 100644 --- a/c_src/tools-util.c +++ b/c_src/tools-util.c @@ -681,6 +681,15 @@ static int kstrtouint_symbolic(const char *s, unsigned int base, unsigned *res) struct bpos bpos_parse(char *buf) { + if (!strcmp(buf, "POS_MIN")) + return POS_MIN; + + if (!strcmp(buf, "POS_MAX")) + return POS_MAX; + + if (!strcmp(buf, "SPOS_MAX")) + return SPOS_MAX; + char *orig = strdup(buf); char *s = buf; |