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 862fd91df0)
This commit is contained in:
Beniamino Galvani 2015-05-29 17:37:26 +02:00
parent afd1bf5642
commit 1ab766b61b
2 changed files with 4 additions and 4 deletions

View file

@ -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)

View file

@ -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);