diff options
| author | Geoff Rehmet <csgr@FreeBSD.org> | 1994-09-11 21:30:09 +0000 |
|---|---|---|
| committer | Geoff Rehmet <csgr@FreeBSD.org> | 1994-09-11 21:30:09 +0000 |
| commit | 282d7272803489b87965bfd48d683b4218014936 (patch) | |
| tree | be06331550ca20fa4bea8f4c31136cc0d7c2a49b /bin/test | |
| parent | fcccde58934f4820887722fdd5c67040a5b87647 (diff) | |
Notes
Diffstat (limited to 'bin/test')
| -rw-r--r-- | bin/test/test.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/bin/test/test.c b/bin/test/test.c index 832257e293234..bde66b9fabace 100644 --- a/bin/test/test.c +++ b/bin/test/test.c @@ -529,6 +529,11 @@ get_int(v, lp) for (; *v && isspace(*v); ++v); + if(!*v) { + *lp = 0; + return; + } + if (isdigit(*v) || ((*v == '-' || *v == '+') && isdigit(*(v+1)))) { errno = 0; val = strtol(v, &ep, 10); |
