From a51ca42b183aa2c52f4b4cf789dcf8c07cb91541 Mon Sep 17 00:00:00 2001 From: James Golovich <james@gnuinter.net> Date: Thu, 4 Mar 2004 21:45:21 +0000 Subject: [PATCH] Make the Wait application accept time with fractions of a second git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@2333 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- pbx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pbx.c b/pbx.c index 8db8db4f9b..5e197f16dd 100755 --- a/pbx.c +++ b/pbx.c @@ -338,8 +338,8 @@ static struct pbx_builtin { { "Wait", pbx_builtin_wait, "Waits for some time", -" Wait(seconds): Waits for a specified number of seconds, then returns 0.\n" }, - +" Wait(seconds): Waits for a specified number of seconds, then returns 0.\n" +"seconds can be passed with fractions of a second. (eg: 1.5 = 1.5 seconds)\n" }, }; /* Lock for the application list */ @@ -4287,8 +4287,8 @@ static int pbx_builtin_wait(struct ast_channel *chan, void *data) { int ms; /* Wait for "n" seconds */ - if (data && atoi((char *)data)) { - ms = atoi((char *)data) * 1000; + if (data && atof((char *)data)) { + ms = atof((char *)data) * 1000; return ast_safe_sleep(chan, ms); } return 0; -- GitLab