Commit Graph

67 Commits

Author SHA1 Message Date
paulc 407bc8cf66 Added a validity check method to DataNode and some descendants.
A DataSource will remove invalid consumers that returned zero.


git-svn-id: http://voip.null.ro/svn/yate@2854 acf43c95-373e-0410-b603-e72c3f656dc1
2009-09-23 14:50:51 +00:00
paulc 2d0f41a0e4 Added parameter to ThreadedSource::looping() so it can keep running while it has consumers.
Fixed behavior of wave and tone "override" and "replace" methods.


git-svn-id: http://voip.null.ro/svn/yate@2835 acf43c95-373e-0410-b603-e72c3f656dc1
2009-09-14 11:02:27 +00:00
paulc 2ebf04b2a3 The worker thread of ThreadedSource now keeps it referenced.
New methods of DataEndpoint, CallEndpoint and ThreadedSource allow easier handling of concurrent operations.
Modules using ThreadedSource were modified to use the new API.


git-svn-id: http://voip.null.ro/svn/yate@2827 acf43c95-373e-0410-b603-e72c3f656dc1
2009-09-07 23:49:12 +00:00
paulc 09b07f4b00 Added Semaphore class, made Mutex derive from (new class) Lockable, made Lock able to get a lock on any Lockable - Mutex or Semaphore.
Use pthread_mutex_timedlock and sem_timedwait if available on platform.
Fixed a bug in the IAX channel exposed by Mutex having virtual methods.


git-svn-id: http://voip.null.ro/svn/yate@2761 acf43c95-373e-0410-b603-e72c3f656dc1
2009-07-22 12:57:14 +00:00
paulc 2f1a5ff2f6 Added flags to data forwarded through DataNodes.
The amount of consumed data is returned to the source.


git-svn-id: http://voip.null.ro/svn/yate@2745 acf43c95-373e-0410-b603-e72c3f656dc1
2009-07-02 09:24:33 +00:00
paulc 2b8a5e0614 Made DataSource inherit Mutex instead of having it as a field.
git-svn-id: http://voip.null.ro/svn/yate@2614 acf43c95-373e-0410-b603-e72c3f656dc1
2009-05-05 20:49:05 +00:00
paulc 5227505c00 Added names to the Mutex class to ease debugging of deadlocks.
git-svn-id: http://voip.null.ro/svn/yate@2611 acf43c95-373e-0410-b603-e72c3f656dc1
2009-05-05 12:25:31 +00:00
paulc 08b2064e3d Merged branches/marian/client up to rev. 2134.
git-svn-id: http://voip.null.ro/svn/yate@2135 acf43c95-373e-0410-b603-e72c3f656dc1
2008-08-04 02:06:00 +00:00
paulc 1638bb179b Reduce contention by dereferencing some objects after dropping mutex locks.
git-svn-id: http://voip.null.ro/svn/yate@2009 acf43c95-373e-0410-b603-e72c3f656dc1
2008-06-03 16:20:32 +00:00
paulc 6d1377fb4e Fixed potential crash in XDEBUG compiled code.
git-svn-id: http://voip.null.ro/svn/yate@1580 acf43c95-373e-0410-b603-e72c3f656dc1
2008-01-04 18:37:28 +00:00
paulc deb6835292 Removed excessively complex expression.
git-svn-id: http://voip.null.ro/svn/yate@1579 acf43c95-373e-0410-b603-e72c3f656dc1
2008-01-04 18:35:07 +00:00
paulc 99bf9dabf9 Added info message when one or both formats are not set.
git-svn-id: http://voip.null.ro/svn/yate@1578 acf43c95-373e-0410-b603-e72c3f656dc1
2008-01-04 18:05:59 +00:00
paulc 1a79d8b770 Changed the unlocking order to prevent races. Perform cleanups in the
destroyed() method instead of the destructor.


git-svn-id: http://voip.null.ro/svn/yate@1357 acf43c95-373e-0410-b603-e72c3f656dc1
2007-06-08 18:33:33 +00:00
paulc b4350bddd5 Use TelEngine::destruct(obj) or GenObject::destruct() wherever applicable.
git-svn-id: http://voip.null.ro/svn/yate@1325 acf43c95-373e-0410-b603-e72c3f656dc1
2007-05-15 15:40:50 +00:00
paulc 9a71223e56 Fixed another stereo->mono conversion bug.
git-svn-id: http://voip.null.ro/svn/yate@1296 acf43c95-373e-0410-b603-e72c3f656dc1
2007-05-05 15:57:08 +00:00
paulc 94132dc141 Fixed mono buffer allocation (fatal bug) and signedness of averaging.
git-svn-id: http://voip.null.ro/svn/yate@1295 acf43c95-373e-0410-b603-e72c3f656dc1
2007-05-05 14:06:41 +00:00
paulc 193cdcb095 Avoid useless mutex lock when thread is already gone.
git-svn-id: http://voip.null.ro/svn/yate@1282 acf43c95-373e-0410-b603-e72c3f656dc1
2007-04-20 00:07:25 +00:00
paulc af062b9474 Fortified against a race condition that could lead to double deletion.
git-svn-id: http://voip.null.ro/svn/yate@1279 acf43c95-373e-0410-b603-e72c3f656dc1
2007-04-18 00:51:28 +00:00
paulc df7c0f7a20 Support for stereo a-law and mu-law, capability to write them to .au file.
git-svn-id: http://voip.null.ro/svn/yate@1248 acf43c95-373e-0410-b603-e72c3f656dc1
2007-04-06 13:37:56 +00:00
paulc d74dc8bd26 Added static method that computes all transcodings possible from a given
format list.


git-svn-id: http://voip.null.ro/svn/yate@1232 acf43c95-373e-0410-b603-e72c3f656dc1
2007-03-26 17:20:34 +00:00
paulc bf8241127f Replaced a possibly undefined code sequence with a slightly longer code.
git-svn-id: http://voip.null.ro/svn/yate@1205 acf43c95-373e-0410-b603-e72c3f656dc1
2007-02-28 00:25:47 +00:00
paulc 5e3ebe937b Disable chained factories when one of the child factories is disabled.
git-svn-id: http://voip.null.ro/svn/yate@1173 acf43c95-373e-0410-b603-e72c3f656dc1
2007-01-22 03:53:17 +00:00
paulc fba53dfec5 Implemented an alternative way of destroying a ThreadedSource from the data
pumping thread itself, should fix most threading related problems.


git-svn-id: http://voip.null.ro/svn/yate@1162 acf43c95-373e-0410-b603-e72c3f656dc1
2007-01-12 22:16:38 +00:00
paulc 73e2bc9c37 Fixed building chains of more than two translators.
Reference: last issue of bug report #60 by mikma.


git-svn-id: http://voip.null.ro/svn/yate@1118 acf43c95-373e-0410-b603-e72c3f656dc1
2006-11-24 15:03:55 +00:00
paulc b8edd7a4d1 Fixed downsampler - correct signedness in averaging.
Fixed timestamp transformation in resampler.
Reference: first 2 issues of bug report #60 by mikma.


git-svn-id: http://voip.null.ro/svn/yate@1117 acf43c95-373e-0410-b603-e72c3f656dc1
2006-11-24 14:51:21 +00:00
paulc f7c9854af0 Fixed another resampler bug found by mikma.
git-svn-id: http://voip.null.ro/svn/yate@1108 acf43c95-373e-0410-b603-e72c3f656dc1
2006-11-10 17:18:32 +00:00
paulc c5b5a0bd6a Applied patch by mikma that fixes memory allocation in resampler.
git-svn-id: http://voip.null.ro/svn/yate@1106 acf43c95-373e-0410-b603-e72c3f656dc1
2006-11-10 12:10:04 +00:00
paulc 927d5db29a Fixed bug in automatical generation of data timestamps.
git-svn-id: http://voip.null.ro/svn/yate@1030 acf43c95-373e-0410-b603-e72c3f656dc1
2006-09-13 18:52:25 +00:00
paulc dbcc8c9fce Added support for multiple data sniffers.
git-svn-id: http://voip.null.ro/svn/yate@1021 acf43c95-373e-0410-b603-e72c3f656dc1
2006-09-08 09:50:19 +00:00
paulc 3610c579ab Fixed timestamp jumps when switching between different data sources.
git-svn-id: http://voip.null.ro/svn/yate@910 acf43c95-373e-0410-b603-e72c3f656dc1
2006-06-28 17:39:15 +00:00
paulc 3a1938c2c7 Updated copyright and FSF address.
git-svn-id: http://voip.null.ro/svn/yate@815 acf43c95-373e-0410-b603-e72c3f656dc1
2006-05-27 15:08:43 +00:00
paulc 2fc3f41989 Fixed to compile with VC++ 6.
git-svn-id: http://voip.null.ro/svn/yate@810 acf43c95-373e-0410-b603-e72c3f656dc1
2006-05-26 08:16:45 +00:00
paulc f5fcb270db Rewritten most of the codec chaining logic.
Added wideband and stereo formats and some simple translators.


git-svn-id: http://voip.null.ro/svn/yate@809 acf43c95-373e-0410-b603-e72c3f656dc1
2006-05-25 20:40:58 +00:00
paulc 1e3e20fbba Fixed minor bug that mangled timestamps of 1st and 2nd packets.
git-svn-id: http://voip.null.ro/svn/yate@702 acf43c95-373e-0410-b603-e72c3f656dc1
2006-02-24 15:45:35 +00:00
paulc 417ed08bb6 Fixed a minor bug in the SIP stack that caused excessive retransmissions
and prevented reINVITE from working always. More buggy SIP implementations
are accepted (with warnings).
Changed some debug levels and added local debugging make targets.


git-svn-id: http://voip.null.ro/svn/yate@701 acf43c95-373e-0410-b603-e72c3f656dc1
2006-02-23 13:46:20 +00:00
paulc 1698a7705d Worked around a bug in older libpthread - waking up a canceled thread that
was trying to lock a mutex.


git-svn-id: http://voip.null.ro/svn/yate@682 acf43c95-373e-0410-b603-e72c3f656dc1
2006-02-09 18:49:44 +00:00
paulc dcae938051 Fixed self deadlock in one-shot tones.
git-svn-id: http://voip.null.ro/svn/yate@659 acf43c95-373e-0410-b603-e72c3f656dc1
2006-01-20 18:24:23 +00:00
paulc 4f85bac3b8 Fixed a ThreadedSource destruction race found by maciejka.
git-svn-id: http://voip.null.ro/svn/yate@658 acf43c95-373e-0410-b603-e72c3f656dc1
2006-01-20 17:54:25 +00:00
paulc 9211f29772 Fixed several race and deadlock conditions.
RTPGroup no longer corrupts memory if transports are removed from its own thread.


git-svn-id: http://voip.null.ro/svn/yate@654 acf43c95-373e-0410-b603-e72c3f656dc1
2006-01-19 21:13:49 +00:00
paulc 49888b7393 Fixed a nasty bug in Linux TLS initialization.
Improved thread/mutex debugging.


git-svn-id: http://voip.null.ro/svn/yate@652 acf43c95-373e-0410-b603-e72c3f656dc1
2006-01-18 18:28:28 +00:00
paulc 6771d7472e Reference counters are strictly enforced.
git-svn-id: http://voip.null.ro/svn/yate@651 acf43c95-373e-0410-b603-e72c3f656dc1
2006-01-18 16:06:05 +00:00
paulc 400acbf857 Added a much needed Windows random function.
git-svn-id: http://voip.null.ro/svn/yate@648 acf43c95-373e-0410-b603-e72c3f656dc1
2006-01-13 05:09:50 +00:00
paulc 17690f60cb Time lost by data gaps is corrected when attaching override source.
git-svn-id: http://voip.null.ro/svn/yate@628 acf43c95-373e-0410-b603-e72c3f656dc1
2005-12-30 23:51:22 +00:00
paulc 747653ab28 Fixed possible three-way concurency bug clearing DataSource's list.
git-svn-id: http://voip.null.ro/svn/yate@622 acf43c95-373e-0410-b603-e72c3f656dc1
2005-12-29 17:49:52 +00:00
paulc 47f564a018 Added extra checks for DataSource and DataConsumer cleanups.
git-svn-id: http://voip.null.ro/svn/yate@621 acf43c95-373e-0410-b603-e72c3f656dc1
2005-12-28 22:27:53 +00:00
paulc 9a16b13ca2 Added support for overrides (local announcements).
Added some extra info to PRI messages and status.


git-svn-id: http://voip.null.ro/svn/yate@527 acf43c95-373e-0410-b603-e72c3f656dc1
2005-09-28 17:41:31 +00:00
paulc b6e7a421e9 Video and other media support in SIP, removed PosgreSQL modules.
git-svn-id: http://voip.null.ro/svn/yate@493 acf43c95-373e-0410-b603-e72c3f656dc1
2005-09-06 02:51:09 +00:00
paulc 3c92a45874 Mutex related changes in engine and channels.
git-svn-id: http://voip.null.ro/svn/yate@467 acf43c95-373e-0410-b603-e72c3f656dc1
2005-08-02 02:20:00 +00:00
paulc 88a4dd8454 Improved readability of debug messages.
git-svn-id: http://voip.null.ro/svn/yate@422 acf43c95-373e-0410-b603-e72c3f656dc1
2005-07-01 22:35:06 +00:00
paulc 553126de41 *** empty log message ***
git-svn-id: http://voip.null.ro/svn/yate@405 acf43c95-373e-0410-b603-e72c3f656dc1
2005-06-14 20:53:20 +00:00