summaryrefslogtreecommitdiffstats
path: root/libmount/src/optstr.c
diff options
context:
space:
mode:
authorManuel Bentele2019-08-21 14:58:42 +0200
committerManuel Bentele2019-08-21 14:58:42 +0200
commit0692b963aa3cb846d8abab5ef5247c4dbb3fec96 (patch)
treef13776d25da3e1adc1445aef22e7566ac98cbe84 /libmount/src/optstr.c
parentlosetup: added file format option to the man page (diff)
parentpartx: document -d vs. --nr and fix test (diff)
downloadkernel-qcow2-util-linux-0692b963aa3cb846d8abab5ef5247c4dbb3fec96.tar.gz
kernel-qcow2-util-linux-0692b963aa3cb846d8abab5ef5247c4dbb3fec96.tar.xz
kernel-qcow2-util-linux-0692b963aa3cb846d8abab5ef5247c4dbb3fec96.zip
lib/losetup: merge remote-tracking branch 'util-linux/master'kernel-qcow2
Signed-off-by: Manuel Bentele <development@manuel-bentele.de>
Diffstat (limited to 'libmount/src/optstr.c')
-rw-r--r--libmount/src/optstr.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libmount/src/optstr.c b/libmount/src/optstr.c
index c0f438fe2..49fc9cc40 100644
--- a/libmount/src/optstr.c
+++ b/libmount/src/optstr.c
@@ -351,7 +351,9 @@ int mnt_optstr_deduplicate_option(char **optstr, const char *name)
end = ol.end;
opt = end && *end ? end + 1 : NULL;
}
- } while (rc == 0 && opt && *opt);
+ if (opt == NULL)
+ break;
+ } while (rc == 0 && *opt);
return rc < 0 ? rc : begin ? 0 : 1;
}