From: William King Date: Thu, 13 Jun 2013 04:23:52 +0000 (-0700) Subject: If the addr pointer is NULL, better to check first before using it. X-Git-Tag: v1.4.1~64 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3f2f393a7c64119f31cc2bab91bcdb334ea62029;p=thirdparty%2Ffreeswitch.git If the addr pointer is NULL, better to check first before using it. --- diff --git a/src/mod/applications/mod_expr/exprval.c b/src/mod/applications/mod_expr/exprval.c index 856c0f1e7f..b0efaa8453 100644 --- a/src/mod/applications/mod_expr/exprval.c +++ b/src/mod/applications/mod_expr/exprval.c @@ -213,12 +213,11 @@ int exprValListGetAddress(exprValList * vlist, char *name, EXPRTYPE ** addr) exprVal *cur; int result; - /* Not found yet */ - *addr = NULL; - if (vlist == NULL || addr == NULL) return EXPR_ERROR_NULLPOINTER; + /* Not found yet */ + *addr = NULL; if (name == NULL || name[0] == '\0') return EXPR_ERROR_NOTFOUND;