summaryrefslogtreecommitdiffstats
path: root/shlibs/mount/src/optstr.c
diff options
context:
space:
mode:
authorKarel Zak2010-08-24 16:17:16 +0200
committerKarel Zak2011-01-03 12:28:41 +0100
commitabc3d1544b8eac3ec6b28c08f4a1bb34c37ab0f3 (patch)
tree423f3f0358325a625866b99795780ab6d2c3ae72 /shlibs/mount/src/optstr.c
parentlibmount: clean up mnt_fs_set_optstr() (diff)
downloadkernel-qcow2-util-linux-abc3d1544b8eac3ec6b28c08f4a1bb34c37ab0f3.tar.gz
kernel-qcow2-util-linux-abc3d1544b8eac3ec6b28c08f4a1bb34c37ab0f3.tar.xz
kernel-qcow2-util-linux-abc3d1544b8eac3ec6b28c08f4a1bb34c37ab0f3.zip
libmount: cleanup return codes (cache.c)
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'shlibs/mount/src/optstr.c')
-rw-r--r--shlibs/mount/src/optstr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/shlibs/mount/src/optstr.c b/shlibs/mount/src/optstr.c
index 853f5f9b0..ffa93f20a 100644
--- a/shlibs/mount/src/optstr.c
+++ b/shlibs/mount/src/optstr.c
@@ -279,9 +279,9 @@ int mnt_optstr_set_option(char **optstr, const char *name, const char *value)
if (*optstr)
rc = mnt_optstr_locate_option(*optstr, name,
&begin, &end, &val, &valsz);
- if (rc == -1)
+ if (rc < 0)
/* parse error */
- return -1;
+ return rc;
if (rc == 1)
/* not found */
return mnt_optstr_append_option(optstr, name, value);