coverity/13695: Unchecked return value: RI.

Problem    : Unchecked return value (CHECKED_RETURN) @ 8554.
Diagnostic : Real issue.
Rationale  : Other invocations of `do_source` are checked and generate
             an error message if fail. There seems to be no reason why
             this particular instance could not fail the same.
Resolution : Check invocation and generate error message on failure.
This commit is contained in:
Eliseo Martínez
2014-12-14 20:13:31 +01:00
parent 3a61b84543
commit 9b1c939370

View File

@ -8543,7 +8543,9 @@ static void ex_loadview(exarg_T *eap)
fname = get_view_file(*eap->arg);
if (fname != NULL) {
do_source(fname, FALSE, DOSO_NONE);
if (do_source(fname, FALSE, DOSO_NONE) == FAIL) {
EMSG2(_(e_notopen), fname);
}
free(fname);
}
}