Improved handling of potential program error with -msg_op read_sieve. Coverity CID 28723.
This commit is contained in:
parent
97e3e29c44
commit
26308b3947
@ -1954,8 +1954,7 @@ int Xorriso_sieve_get_result(struct XorrisO *xorriso, char *name,
|
|||||||
}
|
}
|
||||||
if(f->next_to_deliver == NULL) {
|
if(f->next_to_deliver == NULL) {
|
||||||
/* Should not happen */
|
/* Should not happen */
|
||||||
*available= 0;
|
goto unexpected_null;
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
if(f->num_words <= 0)
|
if(f->num_words <= 0)
|
||||||
return(1);
|
return(1);
|
||||||
@ -1974,9 +1973,15 @@ int Xorriso_sieve_get_result(struct XorrisO *xorriso, char *name,
|
|||||||
if((*argv)[i] == NULL)
|
if((*argv)[i] == NULL)
|
||||||
goto no_mem;
|
goto no_mem;
|
||||||
} else {
|
} else {
|
||||||
|
/* should not happen */
|
||||||
/* >>> ??? should not happen */;
|
unexpected_null:;
|
||||||
|
Xorriso_msgs_submit(xorriso, 0,
|
||||||
|
"Program error: Unexpected NULL pointer in message sieve.",
|
||||||
|
0, "WARNING", 0);
|
||||||
|
if(*argv != NULL)
|
||||||
|
Xorriso__dispose_words(argc, argv);
|
||||||
|
*available= 0;
|
||||||
|
return(-2);
|
||||||
}
|
}
|
||||||
lst= Xorriso_lst_get_next(lst, 0);
|
lst= Xorriso_lst_get_next(lst, 0);
|
||||||
}
|
}
|
||||||
|
@ -1 +1 @@
|
|||||||
#define Xorriso_timestamP "2015.11.09.133135"
|
#define Xorriso_timestamP "2015.11.10.084903"
|
||||||
|
Loading…
Reference in New Issue
Block a user