diff options
author | Kris Kennaway <kris@FreeBSD.org> | 2000-04-10 11:09:42 +0000 |
---|---|---|
committer | Kris Kennaway <kris@FreeBSD.org> | 2000-04-10 11:09:42 +0000 |
commit | dd9cf0235c4a28f03dc05db7f874118274b1cac1 (patch) | |
tree | 2a4ae68749c83823fce59d928ca92442a2879aa0 /contrib/opie/libopie/readrec.c | |
parent | 32fb311063110a6034449f2a620f025607e1679c (diff) | |
download | src-dd9cf0235c4a28f03dc05db7f874118274b1cac1.tar.gz src-dd9cf0235c4a28f03dc05db7f874118274b1cac1.zip |
Upgrade to OPIE 2.32, from http://www.inner.net/pub/opie/
Notes
Notes:
svn path=/vendor/opie/dist/; revision=59118
Diffstat (limited to 'contrib/opie/libopie/readrec.c')
-rw-r--r-- | contrib/opie/libopie/readrec.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/contrib/opie/libopie/readrec.c b/contrib/opie/libopie/readrec.c index d26002df019d..f6361eb51aa1 100644 --- a/contrib/opie/libopie/readrec.c +++ b/contrib/opie/libopie/readrec.c @@ -1,7 +1,7 @@ /* readrec.c: The __opiereadrec() library function. %%% copyright-cmetz-96 -This software is Copyright 1996-1997 by Craig Metz, All Rights Reserved. +This software is Copyright 1996-1998 by Craig Metz, All Rights Reserved. The Inner Net License Version 2 applies to this software. You should have received a copy of the license with this software. If you didn't get a copy, you may request one from <license@inner.net>. @@ -52,8 +52,14 @@ static int parserec FUNCTION((opie), struct opie *opie) *(c2++) = 0; - if (!(opie->opie_n = atoi(c))) + { + char *c3; + + opie->opie_n = strtoul(c, &c3, 10); + + if (*c3) return -1; + }; if (!(c2 = strchr(opie->opie_seed = c2, ' '))) return -1; @@ -112,7 +118,7 @@ int __opiereadrec FUNCTION((opie), struct opie *opie) } if (!opie->opie_principal) - return -1; + goto ret; { char *c, principal[OPIE_PRINCIPAL_MAX]; |