diff --git a/src/mod/applications/mod_expr/exprfunc.c b/src/mod/applications/mod_expr/exprfunc.c index bf069c4b9f..1e5f9d82fd 100644 --- a/src/mod/applications/mod_expr/exprfunc.c +++ b/src/mod/applications/mod_expr/exprfunc.c @@ -73,7 +73,7 @@ int exprFuncListAdd(exprFuncList * flist, char *name, exprFuncType ptr, int min, if (refmin >= 0 && refmax >= 0) { if (refmin > refmax) { result = refmin; - refmin = max; + refmin = refmax; refmax = result; } } @@ -148,7 +148,7 @@ int exprFuncListAddType(exprFuncList * flist, char *name, int type, int min, int if (refmin >= 0 && refmax >= 0) { if (refmin > refmax) { result = refmin; - refmin = max; + refmin = refmax; refmax = result; } }