diff options
author | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-06-12 16:43:37 +0000 |
---|---|---|
committer | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-06-12 16:43:37 +0000 |
commit | 37dfe0f254ca8487ce8dd26af53d8e85d288c308 (patch) | |
tree | 645c97211073db259b63a6fda5ad8f4381bae24d /apps/app_math.c | |
parent | 2e0ba0bb32ca793f3dafd4476d96bf043074b36d (diff) |
move deprecation warning until after all variable declarations (bug #4514)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@5900 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_math.c')
-rwxr-xr-x | apps/app_math.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/apps/app_math.c b/apps/app_math.c index f9e26e699..630d17b5d 100755 --- a/apps/app_math.c +++ b/apps/app_math.c @@ -82,11 +82,6 @@ static int math_exec(struct ast_channel *chan, void *data) int iaction=-1; static int deprecation_warning = 0; - if (!deprecation_warning) { - ast_log(LOG_WARNING, "Math() is deprecated, please use Set(var=${MATH(...)} instead.\n"); - deprecation_warning = 1; - } - /* dunno, big calulations :D */ char user_result[30]; @@ -95,6 +90,11 @@ static int math_exec(struct ast_channel *chan, void *data) struct localuser *u; + if (!deprecation_warning) { + ast_log(LOG_WARNING, "Math() is deprecated, please use Set(var=${MATH(...)} instead.\n"); + deprecation_warning = 1; + } + if (!data) { ast_log(LOG_WARNING, "No parameters passed. !\n"); return -1; |