Closed achaloyan closed 9 years ago
Reported by achaloyan
on 2009-12-01 17:34:18
Accepted
Hi Derik,
I've played a bit with UniMRCP module load/unload routine ins Asterisk and found 3
issues there
1. Asterisk Connector
I forgot to destroy the logger while unloading module. So file descriptor remained
opened. Fixed in
http://code.google.com/p/unimrcp/source/detail?r=1319
2. UniMRCP tasks
I had a closer look at what valgrind reports running unimrcp server and client even
without Asterisk. It never caused any issue, that's why I didn't pay enough attention
to it before. However there indeed was an issue related to task termination.
Fixed in trunk
http://code.google.com/p/unimrcp/source/detail?r=1320
3. Asterisk crash
This one clearly relates to Asterisk and all the versions are affected. Someone may
want to raise it to Asterisk community too.
Scenario to reproduce
1. Load res_speech_unimrcp module (or any other speech module, it doesn't matter)
2. Do whatever here
3. Unload res_speech_unimrcp
4. Call to Asterisk using the dialplan which use SpeechCreate() without exact name
of
the module, using the default.
5. Asterisk one to one crashes.
The following patch should fix it for Asterisk
--- res_speech.c.org 2007-11-22 03:09:02.000000000 +0400
+++ res_speech.c 2009-12-02 01:51:18.000000000 +0400
@@ -313,7 +313,7 @@
/* We have our engine... removed it */
AST_RWLIST_REMOVE_CURRENT(list);
/* If this was the default engine, we need to pick a new one
*/
- if (!default_engine)
+ if (engine == default_engine)
default_engine = AST_RWLIST_FIRST(&engines);
ast_verb(2, "Unregistered speech recognition engine '%s'\n",
engine_name);
/* All went well */
Please try fixes and provide feedback.
Thanks for the detailed issue report.
Reported by achaloyan
on 2009-12-01 17:55:44
Fixed
Seems it missed also the following to properly terminate tasks/threads
http://code.google.com/p/unimrcp/source/detail?r=1321
Reported by achaloyan
on 2009-12-01 19:36:18
Hi there,
I've submitted the patch to the Asterisk community:
https://issues.asterisk.org/view.php?id=16368
Kind regards,
Derik
Reported by thirionjwf
on 2009-12-02 08:07:32
This looks fine now. I'll continue testing it.
Reported by thirionjwf
on 2010-02-06 21:33:14
Verified
Hi there,
Just to let you know - It looks like the bug has now been fixed in Asterisk with the
patch you've supplied.
https://issues.asterisk.org/view.php?id=16368
Kind regards,
Derik
Reported by thirionjwf
on 2010-02-19 06:31:26
So, I'm delighted that sanity has prevailed and thanks for the update, Derik.
Reported by achaloyan
on 2010-02-19 06:43:26
Originally reported on Google Code with ID 53
Reported by
thirionjwf
on 2009-11-30 20:16:06