[Freeswitch-dev] Pointer to memory pool not always passed when calling switch_core_speech_open()
anthony.minessale at gmail.com
Thu Mar 19 03:39:18 UTC 2020
On Tue, Mar 17, 2020 at 1:47 AM SanveanRu . <fokin.denis at gmail.com> wrote:
> Hi, list!
> I am currently studying the internals of TTS features in Freeswitch.
> There is an unclear moment:
> switch_core_speech_open() is called from several locations, but pointer to
> session's memory pool is not always passed during the function call, namely:
> mod_rss.c -- passed
> conference_member.c -- passed
> mod_conference.c -- not passed
> mod_ssml.c -- not passed
> switch_ivr_play_say.c -- not passed
> Is there some rule or reason, that defines in which case pointer should be
> passed and in which not?
If you have a pool already you can pass it and it will be used but now that
pool has to outlast the object.
If you pass NULL, it creates its own pool internally.
> Passing pointer to the memory pool may be convenient way to provide speech
> handle with information about the session, that uses this handle.
> This may be useful when emitting log messages or events, that should be
> fired in context of some active session.
There is nothing in the pool but managed memory, you cannot access it or
anything like that, it has nothing to do with session data.
> PS Also, this pointer is always passed to switch_core_asr_open() call.
> Denis Fokin
> The FreeSWITCH project is sponsored by SignalWire https://signalwire.com
> Enhance your FreeSWITCH install with disruptive priced SMS and PSTN
> Build your next product on our scalable cloud platform.
> Join our online community to chat in real time
> Professional FreeSWITCH Services
> sales at freeswitch.com
> Official FreeSWITCH Sites
> FreeSWITCH-dev mailing list
> FreeSWITCH-dev at lists.freeswitch.org
Anthony Minessale II
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the FreeSWITCH-dev