diff options
Diffstat (limited to 'usr.sbin/sysinstall/variable.c')
-rw-r--r-- | usr.sbin/sysinstall/variable.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/usr.sbin/sysinstall/variable.c b/usr.sbin/sysinstall/variable.c index 0e31ae39..a13b71d 100644 --- a/usr.sbin/sysinstall/variable.c +++ b/usr.sbin/sysinstall/variable.c @@ -4,7 +4,7 @@ * This is probably the last program in the `sysinstall' line - the next * generation being essentially a complete rewrite. * - * $Id: variable.c,v 1.19 1997/06/11 08:41:10 jkh Exp $ + * $Id: variable.c,v 1.20 1997/06/13 14:21:22 jkh Exp $ * * Copyright (c) 1995 * Jordan Hubbard. All rights reserved. @@ -105,6 +105,16 @@ variable_get(char *var) return getenv(var); } +int +variable_cmp(char *var, char *value) +{ + char *val; + + if ((val = variable_get(var))) + return strcmp(val, value); + return -1; +} + void variable_unset(char *var) { |