summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_environment.c
diff options
context:
space:
mode:
authorarchie <archie@FreeBSD.org>1999-11-24 01:03:08 +0000
committerarchie <archie@FreeBSD.org>1999-11-24 01:03:08 +0000
commitd6eae9ff980dd5cb8c77eef5beb21a67fb84ac95 (patch)
tree5d5c85e2a99196d3f704d5a25197f1fa4f3081f2 /sys/kern/kern_environment.c
parente060599533305d04d652d2f055850e47b7b69662 (diff)
downloadFreeBSD-src-d6eae9ff980dd5cb8c77eef5beb21a67fb84ac95.zip
FreeBSD-src-d6eae9ff980dd5cb8c77eef5beb21a67fb84ac95.tar.gz
Change the prototype of the strto* routines to make the second
parameter a char ** instead of a const char **. This make these kernel routines consistent with the corresponding libc userland routines. Which is actually 'correct' is debatable, but consistency and following the spec was deemed more important in this case. Reviewed by (in concept): phk, bde
Diffstat (limited to 'sys/kern/kern_environment.c')
-rw-r--r--sys/kern/kern_environment.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/kern/kern_environment.c b/sys/kern/kern_environment.c
index 995f025..404aaa3 100644
--- a/sys/kern/kern_environment.c
+++ b/sys/kern/kern_environment.c
@@ -86,14 +86,15 @@ getenv_int(char *name, int *data)
quad_t
getenv_quad(char *name, quad_t *data)
{
- const char *value, *vtp;
+ const char *value;
+ char *vtp;
quad_t iv;
if ((value = getenv(name)) == NULL)
return(0);
iv = strtoq(value, &vtp, 0);
- if ((vtp == value) || (*vtp != 0))
+ if ((vtp == value) || (*vtp != '\0'))
return(0);
*data = iv;
OpenPOWER on IntegriCloud