[Freeswitch-users] [freeswitch-users] play_and_get_digits is not blocking

Peter Olsson peter.olsson at visionutveckling.se
Tue Aug 10 11:44:35 PDT 2010


Are you using sockets in asynchronous mode? If not, execute() will just queue up to the internal queue and then return imediately. In that case you will need to get the event when the execution has actually been done.

/Peter
________________________________________
Från: freeswitch-users-bounces at lists.freeswitch.org [freeswitch-users-bounces at lists.freeswitch.org] för Paulo Vicentini [vizentini at hotmail.com]
Skickat: den 10 augusti 2010 20:07
Till: freeswitch-users at lists.freeswitch.org
Ämne: Re: [Freeswitch-users] [freeswitch-users] play_and_get_digits is not blocking

Hi,
Basically:
con.api("originate" ,"{ignore_early_media=true,absolute_codec_string=\'PCMA\'}sofia/test/phone at IP  &park ");
con.execute("play_and_get_digits", "3 5 3 5000 # welcome.wav sorry.wav myDigits \\d+",uuid);
and then uuid_getvar uuid myDigits

But con.execute("
play_and_get_digits"  is not blocking so that I can't grab
myDigits.
I put a  breakpoint at switch_play_and_get_digits (session=0x90d5c18, min_digits=3,.. nevertheless con.execute("play_and_get_digits" returned and with extra debugging I realized that switch_api_execute (cmd=0xb76e2b5c "uuid_getvar"...happens before than
#3  0x00cf2d08 in switch_core_session_execute_application_get_flags (
    session=0xb76b5530, app=0xb76793b0 "play_and_get_digits",
    arg=0xb764ef68 "3 15 3 5000 # ivr-enter_ext_pound.wav sorry.wav myDigits \\d+", flags=0x0) at src/switch_core_session.c:1780
#4  0x00d43d73 in switch_ivr_parse_event (session=0xb76b5530, event=0xb7652198)

So that it seems a kind of race condition between ESL and the
core
core event system

PV

________________________________
Date: Mon, 9 Aug 2010 17:42:42 -0700
From: msc at freeswitch.org
To: freeswitch-users at lists.freeswitch.org
Subject: Re: [Freeswitch-users] [freeswitch-users] play_and_get_digits is not blocking



On Mon, Aug 9, 2010 at 5:24 PM, Paulo Vicentini <vizentini at hotmail.com<mailto:vizentini at hotmail.com>> wrote:
Hi, With ESL: this->execute ( 'play_and_get_digits',... $var .. $digits = $this->api_uuid_getvar ( $uuid, $var );

Paste your entire script, or at least a simple example that demonstrates the issue so that we can try it ourselves. Personally, I've not experienced this issue so I would like to know more about the circumstances where you're seeing this.
-MC


_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users at lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
!DSPAM:4c61978b32931921810807!



More information about the FreeSWITCH-users mailing list