Tilghman Lesher
9bb51868ca
Random MOH wasn't really random (bug 8381)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@48045 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-11-27 17:15:54 +00:00
Tilghman Lesher
a99b6a1c97
If the execute fails a second time, make sure that we don't pass back a stale handle
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@47525 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-11-13 05:45:11 +00:00
Russell Bryant
7c651a64a7
If random order is enabled for files mode music on hold, set a random initial
...
position, instead of always starting at the first file, and doing the random
operation only when switching to the next file.
(bug reported by John Lange on the asterisk-dev mailing list)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@47238 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-11-07 01:22:58 +00:00
Russell Bryant
f18766c30a
ignore files in a music on hold directory that begin with '.'
...
(issue #8249 , cboie)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@46964 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-11-02 17:47:56 +00:00
Steve Murphy
d4b36ffde5
a fix for bug 8251; the var_val needs to accept longer strings or mass confusion and a lot of lost time is the result
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@46803 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-11-01 19:52:43 +00:00
Russell Bryant
78ccdbc123
soxmix and Asterisk expect different file extensions for certain formats. This
...
was already handled for the wav49 format. However, it was not handled for
ulaw and alaw. I fixed this in such a way that using the alternate extensions
for ulaw and alaw will only happen if we know we're calling soxmix, and not a
custom script defined using the MONITOR_EXEC variable. The wav49 processing
was left alone so that external scripts will see no behavior change.
(issue #7550 , reported by mnicholson, proposed patch by junky, committed fix
is a bit different)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@46776 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-11-01 18:24:17 +00:00
Russell Bryant
234408e7c1
fix some copy/paste bugs in the checking of arguments for the
...
"control stream file" AGI command (issue #8255 , mnicholson)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@46557 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-10-31 06:13:09 +00:00
Russell Bryant
bf20deeba1
We should always be using _exit() after a fork() or vfork() instead of exit().
...
This is because exit() does some extra cleanup which in some implementations
of vfork(), for example, can actually modify the state of the parent process,
causing very weird bugs or crashes. (issue #7971 , Nick Gavrikov)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@46361 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-10-27 17:36:07 +00:00
Joshua Colp
87803a8ac6
Put in missing \ns on the end of ast_logs (issue #7936 reported by wojtekka)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@43924 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-09-28 18:00:30 +00:00
Russell Bryant
0d9ea31f3a
Fix a problem that occurred if a user entered a digit that matched a bridge
...
feature that was configured using multiple digits, and the digit that was
pressed timed out in the feature digit timeout period. For example, if blind
transfer is configured as '##', and a user presses just '#'. In this situation,
the call would lock up and no longer pass any frames.
(issue #7977 reported by festr, and issue #7982 reported by michaels and
valuable input provided by mneuhauser and kuj. Fixed by me, with testing help
and peer review from Joshua Colp).
There are a couple of issues involved in this fix:
1) When ast_generic_bridge determines that there has been a timeout, it returned
AST_BRIDGE_RETRY. Then, when ast_channel_bridge gets this result, it calls
ast_generic_bridge over again with the same timestamp for the next event.
This results in an endless loop of nothing until the call is terminated.
This is resolved by simply changing ast_generic_bridge to return
AST_BRIDGE_COMPLETE when it sees a timeout.
2) I also changed ast_channel_bridge such that if in the process of calculating
the time until the next event, it knows a timeout has already occured, to
immediately return AST_BRIDGE_COMPLETE instead of attempting to bridge the
channels anyway.
3) In the process of testing the previous two changes, I ran into a problem in
res_features where ast_channel_bridge would return because it determined
that there was a timeout. However, ast_bridge_call in res_features would
then determine by its own calculation that there was still 1 ms before the
timeout really occurs. It would then proceed, and since the bridge broke
out and did *not* return a frame, it interpreted this as the call was over
and hung up the channels.
The reason for this was because ast_bridge_call in res_features and
ast_channel_bridge in channel.c were using different times for their
calculations. channel.c uses the start_time on the bridge config, which
is the time that the feature digit was recieved. However, res_features
had another time, 'start', which was set right before calling
ast_channel_bridge. 'start' will always be slightly after start_time in the
bridge config, and sometimes enough to round up to one ms.
This is fixed by making ast_bridge_call use the same time as
ast_channel_bridge for the timeout calculation.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@43778 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-09-27 16:54:30 +00:00
Joshua Colp
754cb0114f
Don't close the second file descriptor if it's the same as the first one, as it will have already been closed elsewhere and could cause massive panic. (issue #7699 reported by bn999)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@42148 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-09-06 20:02:59 +00:00
Tilghman Lesher
39e622f7cf
Revert last change - breaks retrieval of builtin variables
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@40901 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-08-23 16:05:26 +00:00
Russell Bryant
465207a28d
use pbx_builtin_getvar_helper() so that GET VARIABLE can retrieve global
...
variables (issue #7609 )
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@39935 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-08-15 22:49:41 +00:00
Joshua Colp
a56f08e345
Treat the file as invalid if we have no valid formats for it (issue #7643 reported by KNK)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@38825 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-08-03 19:54:02 +00:00
Kevin P. Fleming
4f3b40fe79
ensure that the 'feature digit timeout' value is taken into account when deciding how long the bridge should run (this fixes a problem report where a digit press that did not invoke a feature is never passed across the bridge)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@38686 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-08-01 23:07:06 +00:00
Joshua Colp
83f9228c1d
Close the stream when file based MOH stop. This won't get rid of their position in the file but it will cause the translation path to be setup again. (issue #7634 reported by asimpson)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@38654 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-08-01 19:20:05 +00:00
Joshua Colp
f41b9baed4
Add missing code to bring transferee channel out of MOH/autoservice under certain circumstance (issue #7611 reported by guillecabeza with minor mods by myself)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@38585 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-07-31 17:09:10 +00:00
Kevin P. Fleming
648bc1828d
remove some more bad examples of using printf
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@37419 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-07-12 13:54:10 +00:00
Russell Bryant
9807f83d64
fix a place where a frame would be free'd twice
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@33693 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-12 20:40:11 +00:00
Tilghman Lesher
070d4d3976
Move set priority up, because at this point in the code, stdout is no longer
...
the console. If we're unable to set priority, the error goes to Asterisk as
if it were an AGI command (issue 7335).
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@33615 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-12 15:27:18 +00:00
Russell Bryant
9c5890a138
when using moh files mode, don't look for a file past the number of files
...
that have been loaded, or worse, past the size of the files array
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@31775 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-03 17:02:49 +00:00
Kevin P. Fleming
3feead3415
remove pointless forcing of the channel into SLINEAR mode; the write format will be set later based on the file that is chosen to be played to the channel
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@31555 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-01 21:46:50 +00:00
Russell Bryant
71d9095626
if the connection to a FastAGI server fails because of a timeout, log a more
...
informative log message
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@31194 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-31 23:50:00 +00:00
Kevin P. Fleming
e9d164d468
support video recording via AGI 'RECORD FILE' command (issue #7068 )
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@29973 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-24 16:59:20 +00:00
Kevin P. Fleming
75ca02dbaa
backport some mutex initialization and linked list handling fixes from trunk
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@29732 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-23 17:15:23 +00:00
BJ Weschke
f1c97e7df8
Fix a potential leak and correct (hopefully) a segfault under certain conditions. #6784 (vovan and perry testing)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@29696 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-23 15:58:24 +00:00
Joshua Colp
7018a80e91
Use the correct language when playing the transfer sound (issue #7109 reported by casper)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@29512 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-22 20:15:04 +00:00
BJ Weschke
1795ff12cd
When an application that is executed via applicationmap and exits non-zero, make sure that we pass through the correct return value from the application to make sure a segfault doesn't occur by a bridge trying to continue when it should not. Also, when executing applications via applicationmap, make sure that the application is executed against the channel whose DTMF caused it to be fired off in the first place. (part 1/2 of #7090 - this is the only fix that will be applied to both 1.2 and /trunk) acunningham and blitzrage on testing...
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@29196 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-21 15:16:59 +00:00
Joshua Colp
72fe69919c
Incorrect log statement when playing transfer sounds (issue #7008 reported and fixed by nathan)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@25442 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-08 11:16:10 +00:00
Tilghman Lesher
00c0af845d
Bug 6864 - drop realtime priority on ALL external processes
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@24019 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-01 20:44:24 +00:00
Tilghman Lesher
6abf8e5e92
Bug 6544 - when we remove a music class, the thread servicing it should die
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@20966 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-17 17:00:16 +00:00
BJ Weschke
4a40420978
Don't say that we can pass an 'exten' argument in the documentation of Park() when we really cannot. #6902 (opsys)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@18866 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10 17:29:51 +00:00
Joshua Colp
52aa07e2b2
Do not exceed the array size for maximum allowed moh files. (issue #6842 )
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@16534 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30 17:55:28 +00:00
Olle Johansson
b97c1529fc
Set initial value on adsipark
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@16346 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30 01:34:53 +00:00
Joshua Colp
0a0470ad00
Issue #6764 - Return BUSY signal when other party is busy at Attended Transfer (Reported by mnachev)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@14523 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-23 21:51:50 +00:00
Russell Bryant
0cfcb22bbc
fix crash when using the ParkAndAnnounce application. When using this application,
...
there will be no peer channel to play the parking announcement to. (issue #6756 )
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@13961 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-21 18:21:47 +00:00
Russell Bryant
10191fe126
fix inaccurate ack message to ChangeMonitor action (issue #6630 )
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@11561 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-02 19:05:40 +00:00
Tilghman Lesher
536dcc2058
Bug 6615 - Fix 64bit conversion errors by using a long int
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@11503 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-01 17:41:52 +00:00
Russell Bryant
0742e08800
add a missing newline in the agi app description (thanks wunderkin!)
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@11382 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-02-28 18:31:04 +00:00
Kevin P. Fleming
7652fdda20
ensure that FastAGI launcher can handle system call interruption (issue #6449 )
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@10108 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-02-15 00:36:57 +00:00
Matthew Fredrickson
bb886dd488
Fix for ( #6309 ), potential (highly unlikely) memory leak in res_odbc
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@9073 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-02-02 16:12:13 +00:00
Matthew Fredrickson
4efe647169
Backport of fix for #6094
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@8134 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-17 18:29:57 +00:00
Tilghman Lesher
6056391a78
Bug 6081 - fix for memory leak, formatting fixes
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@7823 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-05 23:07:08 +00:00
Olle Johansson
3821e18d08
Fix copyright of changed file
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@7812 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-05 09:13:21 +00:00
Olle Johansson
66f484defe
Issue #5980 : Removing extra CR+LF in manager events - needs port to trunk
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@7795 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-04 21:46:40 +00:00
Russell Bryant
a434f8877a
cast time_t to an int in printf/scanf (issue #5635 )
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@7634 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-12-26 18:19:12 +00:00
Russell Bryant
71d9531e45
check array bounds when parsing arguments to AGI (issue #5868 )
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@7557 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-12-20 20:21:26 +00:00
Kevin P. Fleming
a563eab49a
remove extraneous svn:executable properties
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@7221 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-11-29 18:24:39 +00:00
Kevin P. Fleming
5ec3844077
remove CVS ignore lists, set SVN ignore lists
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@7212 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-11-29 00:46:54 +00:00
Russell Bryant
8c74501001
issue #5826
...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/v1-2@7190 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-11-23 05:49:35 +00:00