Commit Graph

6441 Commits

Author SHA1 Message Date
Michiel van Baak f4617ae2b5 Ignore Redial softkey when no previous dialed number is known
(closes issue #17126)
Reported by: wedhorn
Patches: 
      skinny79xx_redial1.diff uploaded by wedhorn (license 30)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@255851 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-04-02 06:45:54 +00:00
Michiel van Baak cc89bc0a27 Cleanup transmit_* functions
Bulk lot of generally trivial changes for cleaning up the transmit stuff. Line state request has been modified for line only responses.

(closes issue #16994)
Reported by: wedhorn
Patches: 
      skinny-clean07.diff uploaded by wedhorn (license 30)
Tested by: wedhorn


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@255850 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-04-02 06:43:31 +00:00
Mark Michelson 284ac3a4d9 Fix improper comaparison of anonymous URI when getting P-Asserted-Identity.
There was a bug where we split the URI on the @ sign and then attempted
to compare to "anonymous@anonymous.invalid" afterwards. This comparison
could never evaluate true. So now we keep a copy of the URI prior to the
split so that the comparison is valid.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@255701 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-31 22:35:20 +00:00
Russell Bryant c6a759fdfa Merged revisions 255409 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r255409 | russell | 2010-03-30 15:56:00 -0500 (Tue, 30 Mar 2010) | 2 lines
  
  Don't kill Asterisk if the H323 listener does not start.
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@255410 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-30 20:56:26 +00:00
Russell Bryant 0703c27015 chan_usbradio depends on alsa.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@254718 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-25 20:08:40 +00:00
Mark Michelson 54f5e1f840 Add new rtpsource options to the CHANNEL function.
This adds rtpsource options analogous to the rtpdest
functions that already exist. In addition, this fixes
potential crashes which could result due to trying to
read values from nonexistent RTP streams.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@254551 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-25 17:29:47 +00:00
Kevin P. Fleming 42577406fd Improve handling of T.38 re-INVITEs that arrive before a T.38-capable
application is executing on a channel.

This patch addresses an issue found during working with end-users
using res_fax. If an incoming call is answered in the dialplan, or
jumps to the 'fax' extension due to reception of a CNG tone (with
faxdetect enabled), and then the remote endpoint sends a T.38
re-INVITE, it is possible for the channel's T.38 state to be
'T38_STATE_NEGOTIATING' when the application starts up. Unfortunately,
even if the application wants to use T.38, it can't respond to the
peer's negotiation request, because the AST_CONTROL_T38_PARAMETERS
control frame that chan_sip sent originally has been lost, and the
application needs the content of that frame to be able to formulate a
reply.

This patch adds a new 'request' type to AST_CONTROL_T38_PARAMETERS,
AST_T38_REQUEST_PARMS. If the application sends this request, chan_sip
will re-send the original control frame (with
AST_T38_REQUEST_NEGOTIATE as the request type), and the application
can respond as normal. If this occurs within the five second timeout
in chan_sip, the automatic cancellation of the peer reinvite will be
stopped, and the application will 'own' the negotiation process from
that point onwards.

This also improves the code path in chan_sip to allow sip_indicate(),
when called for AST_CONTROL_T38_PARAMETERS, to be able to return a
non-zero response, which should have been in place before since the
control frame *can* fail to be processed properly. It also modifies
ast_indicate() to return whatever result the channel driver returned
for this control frame, rather than converting all non-zero results
into '-1'. Finally, the new request type intentionally returns a
positive value, so that an application that sends
AST_T38_REQUEST_PARMS can know for certain whether the channel driver
accepted it and will be replying with a control frame of its own, or
whether it was ignored (if the sip_indicate()/ast_indicate() path had
properly supported failure responses before, this would not be
necessary).

This patch also modifies res_fax to take advantage of the new request.

In addition, this patch makes sip_t38_abort() actually lock the
private structure before doing its work... bad programmer, no donut.

This patch also enhances chan_sip's 'faxdetect' support to allow
triggering on T.38 re-INVITEs received as well as CNG tone detection.

Review: https://reviewboard.asterisk.org/r/556/



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@254450 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-25 15:27:31 +00:00
Tzafrir Cohen 8acb32460a remove unneeded explicit channel in dahdi ioctls
This patch removes some cases where the channel number for an ioctl was
passed as a member in a struct rather then through the file descriptor.

The gain setting functions passed around a channel which is always 0,
and thus this parameter is simply dropped.

Review: https://reviewboard.asterisk.org/r/584/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@254406 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-25 10:09:24 +00:00
Kevin P. Fleming ae6008ef3a Change per-file debug and verbose levels to be per-module, the way
users expect them to work.

'core set debug' and 'core set verbose' can optionally change the
level for a specific filename; however, this is actually for a
specific source file name, not the module that source file is included
in. With examples like chan_sip, chan_iax2, chan_misdn and others
consisting of multiple source files, this will not lead to the
behavior that users expect. If they want to set the debug level for
chan_sip, they want it set for all of chan_sip, and not to have to
also set it for reqresp_parser and other files that comprise the
chan_sip module.

This patch changes this functionality to be module-name based instead
of file-name based.

To make this work, some Makefile modifications were required to ensure
that the AST_MODULE definition is present in each object file produced
for each module as well.

Review: https://reviewboard.asterisk.org/r/574/



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@253917 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-23 14:22:27 +00:00
Russell Bryant 24137871be Use SHRT_MAX instead of MAXSHORT.
These changes fix build issues I had with this module on FreeBSD.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@253536 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-20 11:33:30 +00:00
Russell Bryant ce4086bbdc Tell the RTP engine API about the initial read and write format.
Peer reviewed out-of-band by file.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@252627 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-15 22:14:18 +00:00
Tilghman Lesher 7d963333e2 THIS IS NOT PYTHON. Indentation doesn't matter, only braces do.
(closes issue #17025)
 Reported by: smurfix
 Patches: 
       sip.patch uploaded by smurfix (license 547)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@252442 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-15 04:25:35 +00:00
Terry Wilson 68d1ded8dd Only change the RTP ssrc when we see that it has changed
This change basically reverts the change reviewed in
https://reviewboard.asterisk.org/r/374/ and instead limits the
updating of the RTP synchronization source to only those times when we
detect that the other side of the conversation has changed the ssrc.

The problem is that SRCUPDATE control frames are sent many times where
we don't want a new ssrc, including whenever Asterisk has to send DTMF
in a normal bridge. This is also not the first time that this mistake
has been made. The initial implementation of the ast_rtp_new_source
function also changed the ssrc--and then it was removed because of
this same issue. Then, we put it back in again to fix a different
issue. This patch attempts to only change the ssrc when we see that
the other side of the conversation has changed the ssrc.

It also renames some functions to make their purpose more clear.

Review: https://reviewboard.asterisk.org/r/540/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@252089 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-12 22:04:51 +00:00
Moises Silva 828bdd8929 add missing mfcr2_skip_category setting
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@252088 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-12 21:57:40 +00:00
Richard Mudgett 76961a63f8 Doxegen this chan_dahdi lock.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251946 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-12 19:05:40 +00:00
Richard Mudgett 7f68a32417 Minor tweaks and comment updates to chan_dahdi.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251821 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-11 18:07:16 +00:00
Richard Mudgett b1ccb1a44e Simplified dahdi_request() channel selection failed reason/cause code.
Also avoid potential crash because cause could be NULL.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251585 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-10 16:55:34 +00:00
Richard Mudgett ee5e65194f Reduce the amount of database access for HAVE_PRI_SERVICE_MESSAGES.
Rework HAVE_PRI_SERVICE_MESSAGES to not use the active values directly
from the database.  Database access is likely expensive.  Database access
now only happens on initialization, destruction, and when the B channel is
taken in or out of service.

This change is not related to call waiting but it would cause the search
for a call waiting interface to be very expensive and slow down D channel
message servicing.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251538 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-10 03:16:50 +00:00
Michiel van Baak 007e52f5dc Clean transmit_* for start/stop media transmission
Small patch changing skinny_set_rtp_peer to use transmit_stopmediatransmission and to use new transmit_startmediatransmission.
Basic testing on 30VIP's by wedhorn
Basic testing on 7960 by me

(closes issue #16956)
Reported by: wedhorn
Patches:
      skinny-clean05b.diff uploaded by wedhorn (license 30)
Tested by: wedhorn,mvanbaak


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251222 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-07 14:53:06 +00:00
Michiel van Baak cf51a99b24 Cleanup transmit_callstate handling
Broke the various functions included in transmit_callstate to their own functions. Transmit_callstate now just transmits callstate.

Generally left the functionality as it was, which highlight some minor code issues (eg multiple transmit_callstate's). I did however revise the hint code usage of the old transmit_callstate as it it not appropriate to put a device on hook based on the change of a hinted device.

(closes issue #16939)
Reported by: wedhorn
Patches:
      skinny-clean04.diff uploaded by wedhorn (license 30)
Tested by: mvanbaak,wedhorn



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251221 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-07 14:46:29 +00:00
Russell Bryant 0c45fc4eda Fix a crash in SIP blind transfer handling found by an automated external test.
The first real test added to the external test suite found a pretty nasty crash
that occurred in Asterisk trunk.  The crash was due to a race condition between
the REFER handling and channel destruction in the channel thread.  After the
transfer has been completed, we go back to the transferrer channel and try to
lock it so we can fire off a CEL event.  However, there was no guarantee that
the channel was still around at that point since it's racing against the channel
thread.

Since ast_channel is a reference counted object, the fix is simple.  The code
unlocks the transferrer channel before finally completing the transfer with
an async goto.  At this point the channel thread is going to start call tear
down and the channel will eventually be destroyed.  To ensure that the channel
is valid when we want to fire off the CEL event, increase the channel's
reference count.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@251137 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-06 14:16:20 +00:00
Russell Bryant 7f8e8d01de Fix up some of chan_sip's usage of the RTP engine API.
The get_local_address() function for an RTP instance was used when building an
SDP, but the results were not honored.  The RTP engine activate() function was
not being used once we have determined that media will now flow.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@250917 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-05 05:03:41 +00:00
Richard Mudgett 73ef4b8daf Removed cdrflags from ast_channel structure.
Only chan_dahdi set a value in cdrflags.  Everyone else just copied it
around the system.  Noone cared about any value it may have contained.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@250565 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-03 19:38:06 +00:00
Jeff Peeler e8a99a9962 Merged revisions 250480 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r250480 | jpeeler | 2010-03-03 13:04:11 -0600 (Wed, 03 Mar 2010) | 15 lines
  
  Make sure to clear red alarm after polarity reversal.
  
  From the issue:
  The automatic overnight line tests (or manual ones) used on UK (BT) lines causes
  a red alarm on a dahdi / TDM400P connected channel. This is because the line
  uses voltage tests (battery loss) and polarity reversal. The polarity reversal
  causes chan_dahdi to initiate v23 CallerID processing but during this the event
  DAHDI_EVENT_NOALARM is ignored so that the alarm is never cleared.
  
  (closes issue #14163)
  Reported by: jedi98
  Patches: 
        chan_dahdi-1.4-inalarm.diff uploaded by jedi98 (license 653)
  Tested by: mattbrown, Chainsaw, mikeeccleston
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@250481 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-03 19:06:06 +00:00
David Vossel 3d4de4a277 Merged revisions 250394 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r250394 | dvossel | 2010-03-03 12:02:27 -0600 (Wed, 03 Mar 2010) | 16 lines
  
  fixes problem with duplicate TXREQ packets
  
  When Asterisk receives an IAX2 TXREQ packet, try_transfer()
  will call store_by_transfercallno() to link the chan_iax2_pvt
  struct into iax_transfercallno_pvts. If a duplicate TXREQ
  packet is received for the same call, the pvt struct will be
  linked into iax_transfercallno_pvts multiple times.  This patch
  fixes this.  Thanks rain for debugging this and providing a patch!
  
  (closes issue #16904)
  Reported by: rain
  Patches:
        iax2-double-txreq-fix.diff uploaded by rain (license 327)
  Tested by: rain, dvossel
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@250395 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-03 18:03:19 +00:00
Jeff Peeler 6bd57e0720 Add new config option to control AMI alarm event reporting in chan_dahdi.
New config parameter "reportalarms" added in chan_dahdi.conf which supports the
following possible values:
"channels": report each channel alarms (current behavior, default for backward compatibility)
"spans": report an "SpanAlarm" event when the span of any configured channel is alarmed
"all": report channel and span alarms (aggregated behavior)
"none": do not report any alarms

(closes issue #16709)
Reported by: nahuelgreco
Patches: 
      chan_dahdi.c.reportalarms.patch uploaded by nahuelgreco (license 162)



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@250392 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-03 17:37:30 +00:00
David Vossel ba1a8d3ff0 fixes signed to unsigned int comparision issue for FaxMaxDatagram value.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@250246 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-03 00:18:28 +00:00
David Vossel 862ebf4d00 fixes adaptive jitterbuffer configuration
When configuring the adaptive jitterbuffer, the target_extra
value not only could not be set from the configuration, but was
not even being set to its proper default.  This value is required
in order for the adaptive jitterbuffer to work correctly.  To resolve
this a config option has been added to expose this value to the conf
files, and a default value is provided when no config specific value
is present.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249893 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-02 19:08:38 +00:00
Alec L Davis 5dbe86a3c2 fix asterisk setting of pritimers from chan_dahdi.conf
regression since sig_pri split.

(issue #16909)
Reported by: alecdavis
Patches: 
      pritimer.asterisk.diff.txt uploaded by alecdavis (license 585)
Tested by: alecdavis



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249759 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-02 06:56:14 +00:00
Michiel van Baak 3f1d9e881e Cleanup display_*message functions.
This patch splits transmit_displaymessage into transmit_clear_display_message and transmit_display_message which better aligns with the skinny protocol. The new transmit_display_message is not used in the current code, but will be and so it is commented.

Moved handle_datetime from this function to onhook and offhook functions (display now properly cleared at the end of a call on 30VIP).

Removed skinny debug messages from inline code as there's an ast_verb in transmit_clear_display_message. Also, removed commentary that it was a clear display as it is now apparent from the function name.

Split transmit_displaypromptmessage into display and clear.

(closes issue #16878)
Reported by: wedhorn
Patches: 
	skinny-clean02.diff uploaded by wedhorn (license 30)
	skinny-clean03.diff uploaded by wedhorn (license 30)



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249670 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-01 19:33:26 +00:00
Michiel van Baak 7a54ee9159 fix endianes issues in chan_skinny
(closes issue #16826)
Reported by: PipoCanaja
Patches: 
      chan_skinny.c_bigendianPatch_20100218.diff uploaded by PipoCanaja (license 994)
Tested by: wedhorn



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249669 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-01 19:27:34 +00:00
Jeff Peeler acd243ca65 Merged revisions 249536 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r249536 | jpeeler | 2010-03-01 11:02:03 -0600 (Mon, 01 Mar 2010) | 11 lines
  
  Modify queued frames from local channels to not set the other side to up
  
  In this case, attended transfers were broken due to ast_feature_request_and_dial
  detecting the channel being set to up before the answer frame could be read and
  therefore failing to mark the channel as ready. This fix is a regression fix for
  244785, which should continue to work properly as well.
  
  (closes issue #16816)
  Reported by: jamhed
  Tested by: jamhed, corruptor
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249538 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-03-01 17:11:31 +00:00
Alec L Davis 98154867e6 overlap receiving: automatically send CALL PROCEEDING when dialplan starts
Following Q.931 5.2.4
When the user has determined that sufficient call information has been received the 
user shall stop T302 and send CALL PROCEEDING to the network.

Previously timeouts were possible if the dialplan took a long time to issue any
response back to the network.

Verified that our local TELCO also does the same.

(issue #16789)
Reported by: alecdavis
Patches: 
      overlap_receiving_trunk.diff.txt uploaded by alecdavis (license 585)
Tested by: alecdavis



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249320 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-27 22:49:51 +00:00
Kevin P. Fleming 7e2145b9ac Merged revisions 249234 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r249234 | kpfleming | 2010-02-27 09:07:59 -0500 (Sat, 27 Feb 2010) | 1 line
  
  add a reference to the now-published IAX2 RFC
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249235 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-27 14:08:35 +00:00
Mark Michelson 86f0690571 Merged revisions 249100 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r249100 | mmichelson | 2010-02-26 11:04:29 -0600 (Fri, 26 Feb 2010) | 8 lines
  
  For T.38 reINVITEs treat a 606 the same as a 488.
  
  (closes issue #16792)
  Reported by: vrban
  Patches:
        t38_606.patch uploaded by vrban (license 756)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@249101 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-26 17:04:58 +00:00
Tilghman Lesher ba75980904 Also kill the .i files, or else the build process will not recreate them, when we
change flags.  Fixes a weird symbol problem mmichelson was having in a group branch,
but also applies to trunk.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@248667 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-24 22:44:55 +00:00
David Vossel 6568b06d29 Merged revisions 248396 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r248396 | dvossel | 2010-02-23 10:26:05 -0600 (Tue, 23 Feb 2010) | 9 lines
  
  fixes invite with replaces deadlock
  
  (closes issue #16862)
  Reported by: pwalker
  Patches:
        replaces_deadlock_1.4 uploaded by dvossel (license 671)
  Tested by: pwalker, dvossel
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@248397 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-23 16:34:39 +00:00
Mark Michelson 3a422d7796 Move the REF_DEBUG comment higher in the include list.
Uncommenting the REF_DEBUG definition where it was in the source
resulted in only a small part of the astobj2 references being logged
to a file. Moving this up higher in the include list causes all references
to be logged as they should be.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@248347 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-22 20:19:00 +00:00
Michiel van Baak 55d1fcdd02 Cleanup transmit_* functions, part 1
Break transmit_tone into transmit_start_tone and transmit_stop_tone as per the skinny protocol. 

(closes issue #16874)
Reported by: wedhorn
Patches:
      skinny-clean01.diff uploaded by wedhorn (license 30)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@248184 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-21 12:09:53 +00:00
Moises Silva 0d838691bc mfcr2 issue 0016844 - Fix portability bit fields and make mfcr2_immediate_accept work again, reported and patched by korihor
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@248003 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-19 18:38:34 +00:00
David Vossel fc0cb53aa5 handle_request_invite revise comment, fix coding guideline issues
I'm working with this code right now trying to analyze a deadlock.
This change is just to clean up a few things before I make a more
complex patch.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@247915 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-19 17:40:26 +00:00
Richard Mudgett 57ee669d9f Merged revisions 247910 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
  r247910 | rmudgett | 2010-02-19 11:18:49 -0600 (Fri, 19 Feb 2010) | 55 lines
  
  Merged revision 247904 from
  https://origsvn.digium.com/svn/asterisk/be/branches/C.2-...
  
  ..........
  r247904 | rmudgett | 2010-02-19 10:49:44 -0600 (Fri, 19 Feb 2010) | 49 lines
  
  Make chan_misdn DTMF processing consistent with other channel technologies.
  
  The processing of DTMF tones on the receiving side of an ISDN channel is
  inconsistent with the way it is handled in other channels, especially
  DAHDI analog.  This causes DTMF tones sent from an ISDN phone to be
  doubled at the connected party.
  
  We are using the following 2 options of misdn.conf
  1) astdtmf=yes
  2) senddtmf=yes
  
  Option one is necessary because the asterisk DSP DTMF detection is better
  than mISDN's internal DSP.  Not as many false positives.
  
  Option two is necessary to transmit DTMF tones end to end when mISDN
  channels are connected to SIP channels with out of band DTMF for example.
  
  The symptom is that DTMF tones sent by an ISDN phone are doubled on the
  way through asterisk when two mISDN channels are connected with a Local
  channel in between or if it is bridged to an analog channel.
  
  The doubling of DTMF tones is because DTMF is passed inband to asterisk by
  the mISDN channel and passed out of band once again after the release of
  the DTMF tone.  Passing it inband is wrong.  Neither an analog channel nor
  SIP channel passes DTMF inband if configured to inband DTMF.  Analog and
  SIP channels filter out the DTMF tones because they use the voice frames
  returned by ast_dsp_process.  But chan_misdn passes the unfiltered input
  voice frames instead.
  
  To overcome one aspect of the problem, the doubling of DTMF tones when two
  mISDN channels are directly bridged, someone made an 'optimization', where
  in that case the DTMF tone passed out-of-band to the peer channel is not
  translated to an inband tone at the transmit side.  This optimization is
  bad because it does not work in general.  For example, analog channels or
  mISDN channels when bridged through an intermediary local channel will
  generate DTMF tones from out-of-band information.  Also, of course, it
  must not be done when there is no inband DTMF available.
  
  This patch fixes the issue.  Now chan_misdn will filter the received
  inband DTMF signal the same as other channel types.
  
  Another change included: No need to build an extra translation path
  because ast_process_dsp does it if required.
  
  Patches:
  	misdn-dtmf.patch
  
  JIRA ABE-2080
................


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@247914 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-19 17:33:33 +00:00
Tilghman Lesher 6fb7e0ece7 If the peer record is from realtime, it could be set to 0, due to MySQL not representing NULL well in integer columns.
NULL means the value is not specified for the column, which normally means
the driver uses whatever is the default value.  However, on MySQL, placing
a NULL in either a float or integer column results in a retrieval of the 0
value.  Hence, users get an errant error on load.  This patch suppresses
that error and makes the value as if it was not there.

Note that this cannot be done in the realtime driver, because the lack of
difference between NULL and 0 can only be intepreted correctly by the
driver itself.  If we did it in the realtime driver, then it would be
effectively impossible to set any realtime field to 0, because it would act
as if the field were unspecified and possibly take on a different value.

(closes issue #16683)
 Reported by: wdoekes


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@247787 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-18 21:42:53 +00:00
Tilghman Lesher e7a5fb5459 Make all of the various rtpqos parameters in this branch available from the CHANNEL function.
Also includes a test for retrieving rtpqos parameters, including a NULL RTP
driver.  Additionally, some further separation of the SIP internal API into
headers was necessary.

(closes issue #16652)
 Reported by: kkm
 Patches: 
       20100204__issue16652.diff.txt uploaded by tilghman (license 14)
 
Review: https://reviewboard.asterisk.org/r/501/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@247124 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-17 06:25:15 +00:00
Tilghman Lesher 22b144cef4 Change the blanket rules to delete .lastclean on all CFLAGS menuselect targets to be more particular.
This change builds upon the recent change to menuselect to add 'touch_on_change'
as an attribute of both categories and members.  This should allow only the most
invasive defines to cause a complete rebuild, while defines which only affect a
subset of modules will only cause a rebuild of that smaller set.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246789 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-16 00:52:45 +00:00
Tilghman Lesher b26b519159 Allow Timer B to be set on the peer, and ensure SIP rules are followed (or warn) in comparison to Timer T1.
(closes issue #16643)
 Reported by: nahuelgreco
 Patches: 
       20100204__issue16643.diff.txt uploaded by tilghman (license 14)
 Tested by: oej


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246724 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-16 00:19:38 +00:00
Richard Mudgett b2a1ad7946 Restore triedtopribridge flag code removed in -r211197.
Ooops.  Failed to note that we were inside a for loop and
pri_channel_bridge() needs to be executed only once.


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246669 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-15 22:08:23 +00:00
David Vossel 2003243947 chan_sip parse code refactoring plus two new unit tests
Code Refactoring Changes
- read_to_parts() moved to reqresp_parser.c and has been renamed as
  get_name_and_number()
- get_in_brackets() moved to reqresp_parser.c
- find_closing_quotes() added to sip_utils.h
Logic Changes
- get_name_and_number() now uses parse_uri() and get_calleridname()
  for parsing. Before this change only names within quotes were
  found, when names not within quotes are possible.
New Unit Tests
-sip_get_name_and_number_test
-sip_get_in_brackets_test

(closes issue #16707)
Reported by: Nick_Lewis
Patches:
      issue16706.diff uploaded by dvossel (license 671)

Review: https://reviewboard.asterisk.org/r/499/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246627 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-15 15:45:02 +00:00
David Vossel 72dcd51cc8 fixes areas where port should be removed from domain during parsing
A patch was committed recently that converted duplicate uri parsing
code to use the parse_uri function.  There were two instances where
this conversion did not mimic previous behavior exactly because the
port was not being parsed off the end of the domain. In order to do
this, a dummy pointer argument needs to be passed into parse_uri so
it will know it must parse out the port from the domain.  If a port
output paramenter is not present,   the domain is returned with the
port still attached.



git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246420 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-12 17:59:39 +00:00
David Vossel 6d9c531237 fixes some test description formatting inconsistencies so log file looks nice
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@246338 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2010-02-11 21:57:37 +00:00