coverity: drop second (redundant) block

Don't proceed to try the mount if we failed to create the
target if it didn't exist.

Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
This commit is contained in:
Serge Hallyn 2015-09-26 14:44:40 -05:00
parent 6f2944c172
commit d7c8805c10

View File

@ -1849,9 +1849,6 @@ static inline int mount_entry_on_generic(struct mntent *mntent,
if (ret < 0) if (ret < 0)
return optional ? 0 : -1; return optional ? 0 : -1;
if (ret < 0 && !optional)
return -1;
cull_mntent_opt(mntent); cull_mntent_opt(mntent);
if (parse_mntopts(mntent->mnt_opts, &mntflags, &mntdata) < 0) { if (parse_mntopts(mntent->mnt_opts, &mntflags, &mntdata) < 0) {