app_minivm: Fix possible uninitialized return value.

Declare 'res' initialized to -1 to deal with earlier error paths that
could cause 'res' to be returned uninitialized.

Change-Id: I8ac2a5755bf4174d89ef893e924c940f702b104e
This commit is contained in:
Corey Farrell 2017-11-18 20:29:16 -05:00
parent 4181b6f377
commit 2fab3aacd6
1 changed files with 1 additions and 1 deletions

View File

@ -1252,7 +1252,7 @@ static int sendmail(struct minivm_template *template, struct minivm_account *vmu
struct ast_channel *chan = NULL;
char *fromaddress;
char *fromemail;
int res;
int res = -1;
if (!str1 || !str2) {
return -1;