diff options
author | Beniamino Galvani <bgalvani@redhat.com> | 2015-05-29 17:37:26 +0200 |
---|---|---|
committer | Beniamino Galvani <bgalvani@redhat.com> | 2015-07-22 13:52:46 +0200 |
commit | 1ab766b61bfe1ff3ffcd7585c7ac243c0d7f7a43 (patch) | |
tree | 3879b2fbd829912d8422c8429c253af3fbd011be | |
parent | afd1bf564251f7d72899675b4e44e2f4b6f54e90 (diff) | |
download | NetworkManager-1ab766b61bfe1ff3ffcd7585c7ac243c0d7f7a43.tar.gz |
ifcfg-rh: change type of svTrueValue() return value and argument
Change type of return value and 'def' argument of svTrueValue() to
gint to make clear that it can be something different from TRUE and
FALSE.
(cherry picked from commit 862fd91df06087257dfa2b647172bafc60328487)
-rw-r--r-- | src/settings/plugins/ifcfg-rh/shvar.c | 6 | ||||
-rw-r--r-- | src/settings/plugins/ifcfg-rh/shvar.h | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/settings/plugins/ifcfg-rh/shvar.c b/src/settings/plugins/ifcfg-rh/shvar.c index 4a5ca1d186..283aa82611 100644 --- a/src/settings/plugins/ifcfg-rh/shvar.c +++ b/src/settings/plugins/ifcfg-rh/shvar.c @@ -303,11 +303,11 @@ svGetValueFull (shvarFile *s, const char *key, gboolean verbatim) * return FALSE if <key> resolves to any non-truth value (e.g. "no", "n", "false") * return <default> otherwise */ -gboolean -svTrueValue (shvarFile *s, const char *key, gboolean def) +gint +svTrueValue (shvarFile *s, const char *key, gint def) { char *tmp; - gboolean returnValue = def; + gint returnValue = def; tmp = svGetValue (s, key, FALSE); if (!tmp) diff --git a/src/settings/plugins/ifcfg-rh/shvar.h b/src/settings/plugins/ifcfg-rh/shvar.h index 4902541b00..de7a358556 100644 --- a/src/settings/plugins/ifcfg-rh/shvar.h +++ b/src/settings/plugins/ifcfg-rh/shvar.h @@ -62,7 +62,7 @@ char *svGetValueFull (shvarFile *s, const char *key, gboolean verbatim); * return FALSE if <key> resolves to any non-truth value (e.g. "no", "n", "false") * return <def> otherwise */ -gboolean svTrueValue (shvarFile *s, const char *key, gboolean def); +gint svTrueValue (shvarFile *s, const char *key, gint def); gint64 svGetValueInt64 (shvarFile *s, const char *key, guint base, gint64 min, gint64 max, gint64 fallback); |