Tilghman Lesher [Fri, 27 Jun 2008 16:00:05 +0000 (16:00 +0000)]
Revert half of the fix, as this part may have been unnecessary (related to issue #12914)
Requested here: http://lists.digium.com/pipermail/asterisk-dev/2008-June/033658.html
Mark Michelson [Fri, 27 Jun 2008 00:15:54 +0000 (00:15 +0000)]
The monitor-join option for queues was deprecated in favor of using
MixMonitor to mix audio. However, it was pointed out to me that because
of this, the command set for the MONITOR_EXEC variable is ignored as well.
This means that people can't do their own custom mixing commands at the end
of recordings in order to make, for instance, stereo recordings of calls.
With this patch, app_queue will set the "joinfiles" variable for the channel's
monitor if MONITOR_EXEC is not zero-length. This means that for normal audio
mixing, MixMonitor is still the preferred choice, but we allow custom
mixing to be done with the two Monitor streams if desired.
Mark Michelson [Thu, 26 Jun 2008 23:35:29 +0000 (23:35 +0000)]
Improve consistency between app_dial and app_queue with regards
to how language is handled between two channels whose native
language is different. Prior to this patch, app_dial would have
the callee inherit the caller's language, and app_queue would not.
After this patch, app_dial no longer has the language inheritance
capability. This seems to make the most sense since it seems more
natural for a person to hear files played back in his/her native
language instead of the language of the person on the far end of
the call. See the CHANGES file for hints on how to keep the
previous behavior of app_dial if desired.
Add the interface of a queue member to the output of the "queue show" command
so that it can easily be associated with a queue member's name. This helps
so that the appropriate queue member can be removed or paused since the
interface is required, not the member's name.
(closes issue #12783)
Reported by: davevg
Patches:
app_queue.diff uploaded by davevg (license 209) with small mod from me
Prior to this patch, the "queue show" command used cached
information for realtime queues instead of giving up-to-date
info. Now realtime is queried for the latest and greatest in
queue info.
Tilghman Lesher [Thu, 26 Jun 2008 17:06:17 +0000 (17:06 +0000)]
Convert casts to unions, to fix alignment issues on Solaris
(closes issue #12932)
Reported by: snuffy
Patches:
bug_12932_20080627.diff uploaded by snuffy (license 35)
ensure that (whenever possible) if we generate a log message because an ioctl() call to DAHDI/Zaptel failed, that we include the reason it failed by including the stringified error number
Russell Bryant [Thu, 26 Jun 2008 15:37:01 +0000 (15:37 +0000)]
- add get_max_rate timing API call
- change ast_settimeout() to honor max rate in edge cases of file playback
(this will make some warning messages go away at the end of playing back
a file)
Tilghman Lesher [Thu, 26 Jun 2008 01:11:43 +0000 (01:11 +0000)]
Update sample configuration to match what are now the defaults for the prefix.
(closes issue #12838, related to issue #12198)
Reported by: pabelanger
Patches:
http.conf.diff2 uploaded by pabelanger (license 224)
allow tonezone to live in a different place than DAHDI/Zaptel, since dahdi-tools and dahdi-linux are now separate packages and can be installed in different places
don't include tonezone.h in dahdi_compat.h, because only a couple of modules need it
get app_rpt building again after the DAHDI changes
Mark Michelson [Wed, 25 Jun 2008 22:25:20 +0000 (22:25 +0000)]
Fix a bug in the rwlock tracking. ast_rwlock_unlock did not take into
account that multiple threads could hold the same rdlock at the same time.
As such, it expected that when a thread released a lock that it must have
been the last to acquire the lock as well. Erroneous error messages would
be sent to the console stating that a thread was attempting to unlock a lock
it did not own.
Now all threads are examined to be sure that the message is only printed
when it is supposed to be printed.
Occasionally control characters find their way into CallerID. These need to
be stripped prior to placing CallerID in the headers of an email.
(closes issue #12759)
Reported by: RobH
Patches:
20080602__bug12759__2.diff.txt uploaded by Corydon76 (license 14)
Tested by: RobH
Don't access the pvt structure if unable to acquire the lock.
(closes issue #12162)
Reported by: norman
Patches:
12162-lockfail.diff uploaded by qwell (license 4)
Sorry, my testing did not contain the simple case of forkCDR(v),
I am much embarrassed to admit. If I had, I would have
more solidly initialized the opts element for varset.
usleep with a value over 1,000,000 is nonportable. Changing to use sleep()
instead. (closes issue #12814)
Reported by: pputman
Patches:
app_rtp_sleep.patch uploaded by pputman (license 81)
When using a Local channel, started by a call file, with a destination of an
AGI script, the AGI script does not always get notified of a hangup if the
underlying channel hangs up early.
(closes issue #11833)
Reported by: IgorG
Patches:
local_hangup-v1.diff uploaded by IgorG (license 20)
It's possible for a hangup to be received, even just after the initial cid
spill.
(closes issue #12453)
Reported by: Alex728
Patches:
20080604__bug12453.diff.txt uploaded by Corydon76 (license 14)
Mark Michelson [Thu, 19 Jun 2008 22:34:03 +0000 (22:34 +0000)]
Fix attachment behavior when using IMAP storage for voicemails
1. Filenames had an extra "msg" in the attachment name
2. The attachment was being saved twice
Michiel van Baak [Thu, 19 Jun 2008 20:48:33 +0000 (20:48 +0000)]
Older versions of GNU gcc do not allow 'NULL' as sentinel.
They want (char *)NULL as sentinel.
An example is OpenBSD (confirmed on 4.3) that ships with gcc 3.3.4
This commit introduces a contstant SENTINEL which is declared as:
#define SENTINEL ((char *)NULL)
All places I could test compile on my openbsd system are converted.
Update CODING-GUIDELINES to tell about this constant.
Tilghman Lesher [Thu, 19 Jun 2008 19:22:59 +0000 (19:22 +0000)]
Allow alternative extensions to be specified for a user.
(closes issue #12830)
Reported by: jcollie
Patches:
astertisk-trunk-121496-alternate-extensions.patch uploaded by jcollie (license 412)
Russell Bryant [Thu, 19 Jun 2008 18:30:49 +0000 (18:30 +0000)]
- Make res_timing_pthread allow a max rate of 100/sec instead of 50/sec
- change the "timing test" CLI command to let you specify a timing rate to test
Tilghman Lesher [Thu, 19 Jun 2008 17:22:27 +0000 (17:22 +0000)]
Don't change pointers that need to be later passed back for deallocation.
(closes issue #12572)
Reported by: flyn
Patches:
20080613__bug12572.diff.txt uploaded by Corydon76 (license 14)
Only process 40 arguments (20 files) at once with xargs, because some older
shells may force xargs to separate on an odd boundary.
(Closes issue #12883)
Reported by Nik Soggia
The RDTSC instruction was introduced on the Pentium line of microprocessors,
and is not compatible with certain 586 clones, like Cyrix. Hence, asking for
i386 compatibility was always incorrect. See http://en.wikipedia.org/wiki/RDTSC
(Closes issue #12886)
Reported by tecnoxarxa
Add support for saying numbers in Hebrew.
(closes issue #11662)
Reported by: greenfieldtech
Patches:
say.c.patch-12042008 uploaded by greenfieldtech (license 369)
Hebrew-Sounds.ods uploaded by greenfieldtech
(with signficant changes to the spreadsheet by me)
Set the variables top-down, so that if a script sets a variable more than once,
the last one will take precedence.
(closes issue #12673)
Reported by: phber
Patches:
20080519__bug12673.diff.txt uploaded by Corydon76 (license 14)
Brett Bryant [Tue, 17 Jun 2008 21:46:57 +0000 (21:46 +0000)]
Updates all usages of ast_tcptls_session_instance to be managed by reference counts so that they only get destroyed when all threads are done using
them, and memory does not get free'd causing strange issues with SIP.
This code was originally written by russellb in the team/group/issue_11972/ branch.
Tilghman Lesher [Tue, 17 Jun 2008 21:42:42 +0000 (21:42 +0000)]
Add an option, specifying maximum analysis time for talk detection.
(closes issue #12149)
Reported by: davevg
Patches:
app_talkdetect.c.diff uploaded by davevg (license 209)
(Plus a few additional cleanups by moi)
Mark Michelson [Tue, 17 Jun 2008 21:26:31 +0000 (21:26 +0000)]
_ys pointed out in #asterisk-bugs that he was experiencing
a memory leak when running the astobj2 test CLI command. After
searching, it appears the leak was in the command handler itself.
Each object was allocated (recount = 1) and then linked into
a container (refounct = 2). Then at the end of the function,
the container was unreffed, causing all the objects to have
their refcount decremented by one, leaving the refcount for
all objects allocated in that function at 1. I've now added
an extra unref to the mix so that the refcount equals zero
when the container is unreffed.
Steve Murphy [Tue, 17 Jun 2008 20:17:20 +0000 (20:17 +0000)]
Changes to list peers and users in alpha. order, as per a reasonable request in 12494. Due to changes in trunk to use the astobj2 i/f in the sip channel driver, the order of the entries in the config file was lost, thus the output was in a random order, but no longer.
Tilghman Lesher [Tue, 17 Jun 2008 18:23:01 +0000 (18:23 +0000)]
If we don't match registrar when destroying a context, it can cause a crash.
(closes issue #12835)
Reported by: ys
Patches:
pbx.c.diff uploaded by ys (license 281)
Cisco BTS sends SIP responses with a tab between the Cseq number and
SIP request method in the Cseq: header. Asterisk did not handle this
properly, but with this patch, all is well.
davidw pointed out that the holdtime calculation used by
app_queue does not use "boxcar" filtering as the comments
say. The term "boxcar" means that the number of samples used
to calculate stays constant, with new samples replacing the
oldest ones. The queue holdtime calculation uses all holdtime
samples collected since the queue was loaded, so the comment
has been changed to be accurate.
Russell Bryant [Tue, 17 Jun 2008 15:52:13 +0000 (15:52 +0000)]
Merged revisions 123271 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r123271 | russell | 2008-06-17 10:48:31 -0500 (Tue, 17 Jun 2008) | 4 lines
Fix a memory leak in astobj2 that was pointed out by seanbright. When a container
got destroyed, the underlying bucket list entry for each object that was in the
container at that time did not get free'd.
Doug Bailey [Mon, 16 Jun 2008 21:42:46 +0000 (21:42 +0000)]
Clean up code that handles fsk mwi message generation by pulling it from do_monitor and creating its own thread.
Added RP-AS mwi message generation using patches from meneault as a basis.