From 3221a71d632509d8d0d0fdccba4c85a710bc3e8b Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Mon, 21 Apr 2014 20:47:16 -0400 Subject: use the right function here --- src/parser.c | 2 +- src/parser.l | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/parser.c b/src/parser.c index 216089e..51c351a 100644 --- a/src/parser.c +++ b/src/parser.c @@ -2474,7 +2474,7 @@ static void runes_parser_extract_sm_params( } if (modes && (size_t)(pos - buf) < len) { - if (strstr(pos, "0123456789")) { + if (strspn(pos, "0123456789")) { modes[*nparams] = '\0'; } else { diff --git a/src/parser.l b/src/parser.l index 544c623..07b6e3d 100644 --- a/src/parser.l +++ b/src/parser.l @@ -345,7 +345,7 @@ static void runes_parser_extract_sm_params( } if (modes && (size_t)(pos - buf) < len) { - if (strstr(pos, "0123456789")) { + if (strspn(pos, "0123456789")) { modes[*nparams] = '\0'; } else { -- cgit v1.2.3-54-g00ecf