Commit Graph

21749 Commits

Author SHA1 Message Date
Jonathan Rose
749b33018e Backports some documentation for func_curl from 10 to 1.8
For some reason this function was completely undocumented in 1.8. I copied the
10 docs over to 1.8 and removed references to an enumerator that was added in
the Asterisk 10 version of func_curl.  That was the only change I noted.

(closes issue ASTERISK-19186)
Reported by: Olivier Krief


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353818 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-02 18:31:37 +00:00
Mark Michelson
47b3aa6362 Fix TLS port binding behavior as well as reload behavior:
* Removes references to tlsbindport from http.conf.sample and manager.conf.sample
* Properly bind to port specified in tlsbindaddr, using the default port if specified.
* On a reload, properly close socket if the service has been disabled.

A note has been added to UPGRADE.txt to indicate how ports must be set for TLS.

(closes issue ASTERISK-16959)
reported by Olaf Holthausen

(closes issue ASTERISK-19201)
reported by Chris Mylonas

(closes issue ASTERISK-19204)
reported by Chris Mylonas

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



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353770 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-02 16:58:44 +00:00
Jonathan Rose
ad24624751 Fix sip show peers port output, align columns, and fix ami port output.
A previous patch I committed from ASTERISK-16930 unexpectedly changed some output for
the AMI action "sippeers" which this patch changes back. Also, this aligns the output
for the cli command "sip show peers" and fixes another issue that patch introduced by
using ast_sockaddr_stringify calls multiple times without immediately using the pointer.
I also went ahead and did a little janitorial work to clean up whitespace in
_sip_show_peers.

(issue ASTERISK-16930)
(closes issue ASTERISK-19281)
Reported by: Patrick El Youssef
Patches:
	ASTERISK-19281.diff uploaded by Walter Doekes (license 5674)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353769 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-02 16:57:36 +00:00
Jonathan Rose
3c1a9894e8 Use ast_sockaddr_stringify_fmt wrappers for various functions in chan_sip
There are a number of cleaner looking wrappers for ast_sockaddr_stringify_fmt
available which are slightly more readable than using a direct call to
ast_sockaddr_stringify_fmt. This patch switches a number of those calls in
chan_sip to use those wrappers and is generally harmless.

(Closes issue ASTERISK-16930)
Reported by: Michael L. Young
Patches:
	chan_sip-broken-registration-1.8.diff uploaded by Michael L. Young (license 5026)



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353720 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-01 21:05:26 +00:00
Sean Bright
f28f00bd6e Resolve an overlap in the ast_audiohook_flags values.
AST_AUDIOHOOK_TRIGGER_WRITE and AST_AUDIOHOOK_WANTS_DTMF were overlapping which
may have caused unintended side effects.  This patch moves
AST_AUDIOHOOK_TRIGGER_WRITE, and updates AST_AUDIOHOOK_TRIGGER_MODE to reflect
the original intention.

This will affect existing modules that use these flags, so be sure to recompile
as necessary.

(closes issue ASTERISK-19246)
Reported by: feyfre


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353598 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-01 15:50:50 +00:00
Matthew Jordan
3bf654b1dc Added clarification for the VERBOSITY setting to etc_default_asterisk
Clarified that using the VERBOSITY setting in etc_default_asterisk is the
same as using the -v command line switch, which causes Asterisk to launch
in console mode.

(closes issue ASTERISK-17030)
Reported by: Jonas



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353550 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-02-01 15:02:42 +00:00
Terry Wilson
0120bde7d8 Allow res_calendar to be unloaded
The calendaring tech modules depend on res_calendar and initially
res_calendar just bumped the use count so that it couldn't be unloaded.
res_calendar can potentially create many threads and I've seen issues
where the Asterisk shutdown has failed where it looked like these
threads could be the culprit.

This patch adds unload support for res_calendar. Unloading res_calendar
will also unload the dependant tech modules as well.

(closes issue ASTERISK-16744)
Review: https://reviewboard.asterisk.org/r/1657/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353502 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-31 23:41:39 +00:00
Richard Mudgett
c7c7d4dab4 Fix memory leak in error paths for action_originate().
* Fix memory leak of vars in error paths for action_originate().

* Moved struct fast_originate_helper tech and data members to stringfields.

* Simplified ActionID header handling for fast_originate().

* Added doxygen note to ast_request() and ast_call() and the associated
channel callbacks that the data/addr parameters should be treated as const
char *.

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353454 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-31 16:51:06 +00:00
Terry Wilson
d699845a55 Re-link peers by IP when dnsmgr changes the IP
Asterisk's dnsmgr currently takes a pointer to an ast_sockaddr and updates it
anytime an address resolves to something different. There are a couple of
issues with this. First, the ast_sockaddr is usually the address of an
ast_sockaddr inside a refcounted struct and we never bump the refcount of those
structs when using dnsmgr. This makes it possible that a refresh could happen
after the destructor for that object is called (despite ast_dnsmgr_release
being called in that destructor). Second, the module using dnsmgr cannot be
aware of an address changing without polling for it in the code. If an action
needs to be taken on address update (like re-linking a SIP peer in the
peers_by_ip table), then polling for this change negates many of the benefits
of having dnsmgr in the first place.

This patch adds a function to the dnsmgr API that calls an update callback
instead of blindly updating the address itself. It also moves calls to
ast_dnsmgr_release outside of the destructor functions and into cleanup
functions that are called when we no longer need the objects and increments the
refcount of the objects using dnsmgr since those objects are stored on the
ast_dnsmgr_entry struct. A helper function for returning the proper default SIP
port (non-tls vs tls) is also added and used.

This patch also incorporates changes from a patch posted by Timo Teräs to
ASTERISK-19106 for related dnsmgr issues.

(closes issue ASTERISK-19106)

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353371 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-30 23:17:16 +00:00
Alec L Davis
a61f99f985 prevent debug messsges displaying -ve Cseq numbers. Missed in R353320
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353368 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-30 22:40:40 +00:00
Alec L Davis
8fc0050b54 RFC3261 Section 8.1.1.5. The sequence number value MUST be expressible as a 32-bit unsigned integer
* fix: use %u instead of %d when dealing with CSeq numbers - to remove possibility of -ve numbers.

* fix: change all uses of seqno and friends (ocseq icseq) from 'int' or 'unsigned int' to uint32_t.

Summary of CSeq numbers.
An initial CSeq number must be less than 2^31
A CSeq number can increase in value up to 2^32-1
An incrementing CSeq number must not wrap around to 0.

Tested with Asterisk 1.8.8.2 with Grandstream phones.
 
alecdavis (license 585)
Tested by: alecdavis
 
Review: https://reviewboard.asterisk.org/r/1699/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353320 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-30 21:57:49 +00:00
Kevin P. Fleming
2281ba7cef Clarify log WARNING message when port-zero SDP 'm' lines received.
Previously, if an m-line in an SDP offer or answer had a port number of zero,
that line was skipped, and resulted in an 'Unsupported SDP media type...'
warning message. This was misleading, as the media type was not unsupported,
but was ignored because the m-line indicated that the media stream had been
rejected (in an answer) or was not going to be used (in an offer).



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353260 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-30 12:42:16 +00:00
Russell Bryant
d42eaedb15 Find even more network interfaces.
The previous change made the code look for emN and pciN in addition to what
it did originally, which was search for ethN.  However, it needed to be looking
for pciN#N, so that's what it does now.

This also moves the memset() to be before every ioctl().


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353175 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-29 02:42:59 +00:00
Kevin P. Fleming
1efffc8d95 Add 'L16-256' MIME subtype alias for slin16.
Asterisk has supported the 'L16' MIME subtype for 16kHz signed linear (PCM)
audio for quite some time, but some endpoints refer to it as 'L16-256'. This
commit adds this as an alias for the existing format.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353126 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-28 14:49:48 +00:00
Russell Bryant
45bf0ea5b0 Update ast_set_default_eid() to find more network interfaces.
As of Fedora 15, ethN is not the name of ethernet interfaces.  The names
are emN or pciN.  Update some code that searched for interfaces named
ethN to look for the new names, as well.  For more information about why
this change was made, see this page:

    http://domsch.com/blog/?p=455


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@353077 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-28 04:25:25 +00:00
Jonathan Rose
cda638dcfc Make failed PauseMonitor and UnpauseMonitor with no valid channel not close AMI session.
I also went ahead and took a little time to make sure that the manager value
AMI_SUCCESS was used instead of just return 0 being thrown around everywhere since that's
how we handle this stuff these days.

(closes issue ASTERISK-19249)
Reporter: Jamuel Starkey
Patches:
	res_monitor.c-ASTERISK-19249.diff uploaded by Jamuel Starkey (license 5766)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352959 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-27 19:12:34 +00:00
Richard Mudgett
a55030f4fa Audit of ao2_iterator_init() usage for v1.8.
Fixes numerous reference leaks and missing ao2_iterator_destroy() calls as
a result.

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352955 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-27 18:22:39 +00:00
Alec L Davis
4d2f8a9cfd rfc4235 - Section 4.1: Versions MUST be representable using a non-negative 32 bit integer.
If a BLF subscription exists for long enough, using %d may print negative version numbers.
Unlikely, as 2^32 at 1 update per second is ~137 years, or half that before the versions number started going negative.

Tested with Asterisk 1.8.8.2 with Grandstream phones.
 
alecdavis (license 585)
Tested by: alecdavis
 
Review: https://reviewboard.asterisk.org/r/1694/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352862 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-27 00:05:30 +00:00
Alexandr Anikin
197662dd4d Fix outbound DTMF for inband mode (tell asterisk core to generate DTMF
sounds).

(Closes issue ASTERISK-19233)
Reported by: Matt Behrens
Patches:
        chan_ooh323.c.patch uploaded by Matt Behrens (License #6346)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352807 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-26 20:14:50 +00:00
Jonathan Rose
301cc6b1c0 Copy amaflags to sip_pvt from peer during create_addr_from_peer
For whatever reason, we don't have a single function for copying data like this
from SIP peers to the SIP pvt. This patch adds the copying of amaflags to the
sip_pvt, but it would probably be worth discussing this function along with
the others that essentially just copy some amount of data from a peer to a
private.

(Closes issue ASTERISK-19029)
Reported by: Matt Lehner


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352755 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-26 19:06:05 +00:00
Alec L Davis
bd8d057dee Cleanup dialog-info+xml Notify dialog
Make similar to other Notify messages.

sample output:

<?xml version="1.0"?>
<dialog-info xmlns="urn:ietf:params:xml:ns:dialog-info" version="715" state="full" entity="sip:8523@192.168.x.xx">
<dialog id="8523">
<state>terminated</state>
</dialog>
</dialog-info>

Tested with Asterisk 1.8.8.2 with Grandstream phones.
 
alecdavis (license 585)
Tested by: alecdavis
 
Review: https://reviewboard.asterisk.org/r/1693/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352704 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-26 06:27:07 +00:00
Paul Belanger
b0a70ade4b Fix -Werror=unused-but-set-variable compiler error (gcc 4.6.2)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352643 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-25 22:21:30 +00:00
Kevin P. Fleming
d4dc9894f2 Avoid unnecessary rebuilds of main/test.c.
main/test.c includes "asterisk/version.h", when it should include
"asterisk/ast_version.h" instead (and it should use the ast_get_version()
and ast_get_version_num() functions). This commit modifies it to extract
the Asterisk version information using the proper APIs, and as a result means
that main/test.c no longer needs to be rebuilt when a Subversion checkout
is updated or modified.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352612 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-25 21:16:54 +00:00
Terry Wilson
054c466a2f Remove some extraneous debugging from registry memleak fix
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352551 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-25 17:28:29 +00:00
Terry Wilson
f1dc1012ae Clean up some SIP registry-related memory leaks
1) Be sure and free at unload the epa_backend we allocate at startup
2) Do the same sip_registry cleanup at unload we do at reload

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352514 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-25 16:46:56 +00:00
Jonathan Rose
5de11bfd6e Redocuments sip types peer, user, friend in sip.conf.sample
There was faulty information in the sample config describing user as a synonym for friend
so it has been changed to better elaborate on the differences between the three entity
types.

(closes issue ASTERISK-15537)
Reported by: yarique



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352511 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-25 16:39:15 +00:00
Mark Michelson
7c7615e399 Don't do a DNS lookup on an outbound REGISTER host if there is an outbound proxy configured.
(closes issue ASTERISK-16550)
reported by: Olle Johansson



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352424 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-24 22:17:46 +00:00
Jonathan Rose
1965cea7ab Set core sounds version to 1.4.22.
Now that we have the right license for the Russian 1.4.22 sounds as well as the sounds
for the Australian English 1.4.22 sounds, we can finally set the sounds to use 1.4.22!

(closes issue ASTERISK-18978)
Reported by: Cameron Twomey
Patches:
	confbridge.tar.001 uploaded by Cameron Twomey
    confbridge.tar.002 uploaded by Cameron Twomey


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352367 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-24 20:33:02 +00:00
Richard Mudgett
cf450c7db1 Fix locking issues with channel datastores in func_odbc.c.
* Fixed a potential memory leak when an existing datastore is manually
destroyed by inline code instead of calling ast_datastore_free().

(closes issue ASTERISK-17948)
Reported by: Archie Cobbs

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


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352291 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-24 16:59:59 +00:00
Joshua Colp
d7a25693c9 Move RTP timeout check to before bridged channel check so it is actually executed.
(issue ASTERISK-19179)
Reported by: TSAREGORODTSEV Yury

(closes issue ASTERISK-14534)
Reported by: kriborgen
Patches:
	chan_sip.patch uploaded by kriborgen (license 6138)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352287 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-24 16:30:36 +00:00
Mark Michelson
e41e647429 Fix grammar of comment.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352230 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-23 20:30:21 +00:00
Mark Michelson
e2a7c10b97 Fix blind transfers from failing if an 'h' extension is present.
This prevents the 'h' extension from being run on the transferee
channel when it is transferred via a native transfer mechanism such
as SIP REFER.

(closes ASTERISK-19173)
Reported by: Ross Beer
Tested by: Kristjan Vrban
Patches:
	ASTERISK-19173 by Mark Michelson (license 5049)

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



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352199 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-23 20:06:25 +00:00
Matthew Jordan
11105d0cd3 Correctly apply FAXOPT settings (V17, V27, V29) before starting spandsp layer
While the FAXOPT function could be used to set the modem capabilities, the
input to that function was not being applied correctly to the spandsp layer.
This patch applies the current model capabilities before starting the spandsp
layer.

(closes issue: ASTERISK-16409)
Reported by: Kristijan Vrban
Tested by: Matt Jordan, Matthew Nicholson
Patches:
  spandsp-modems-1.8.diff uploaded by mnicholson (license 5081)
  spandsp-modems-10.diff uploaded by mnicholson (license 5081)



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352144 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-23 19:12:14 +00:00
Richard Mudgett
fe7fb3772b Fix sip_cfg.notifycid to be set with the defined enum values.
The invalid value used when notifycid was enabled was benign.  As far as
the code was concerned -1 and 1 are equivalent.

(closes issue ASTERISK-19232)
Reported by: Eike Kuiper


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352090 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-23 17:33:34 +00:00
Richard Mudgett
8a536e73cb Fix ast_app_dtget() time unit inconsistency.
Note: Noone calls ast_app_dtget() with the timeout parameter of zero so
the bad code normally will never get executed.

* Fix unnecessary floating point division in func_timeout.c
timeout_write() when all other values are integers.

(closes issue ASTERISK-16817)
Reported by: Dmitry Andrianov


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352029 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-21 00:20:07 +00:00
Mark Michelson
1f178bb083 Remove XXX comment that is not necessary.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352016 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-21 00:08:06 +00:00
Mark Michelson
27d894d624 Fix RTP reference leak.
If a blind transfer were initiated using a REFER without a prior
reINVITE to place the call on hold, AND if Asterisk were sending
RTCP reports, then there was a reference for the RTP instance
of the transferer.

This fixes the issue by merging two similar but slightly conflicting
sections of code into a single area. It also adds a stop_media_flows()
call in the case that the transferer's UA never sends a BYE to us
like it is supposed to.

(issue ASTERISK-19192)

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



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352014 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-21 00:04:13 +00:00
Kinsey Moore
2cefb60505 More corrections for the ilbc code
These changes are in a file that is not compiled by default, and so were
missed on earlier checks.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351860 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-20 19:34:20 +00:00
Kinsey Moore
cc1bed34f9 Allow ilbc code to build under dev mode
GCC 4.6.3 found some set/unused variables in the ILBC code.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351858 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-20 19:19:11 +00:00
Jonathan Rose
e2629535cb Accidentally left off a semicolon only in 1.8 somehow for previous patch.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351765 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-20 16:01:32 +00:00
Matthew Jordan
4a76662bca Remove unused variable 'tmp' from helpfun in ilbc codec
gcc version 4.6.2 caught an unused variable in the ilbc codec
library.  This would prevent compilation with --enable-dev-mode;
variable removed.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351760 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-20 15:48:48 +00:00
Jonathan Rose
836e26a426 Adds setting of mwi_from field to check_auth_result check_peer_ok
(closes ASTERISK-19057)
Reported By: Yuri
Patches: 348360chan_sip.diff uploaded by Yuri (license 5242)



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351759 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-20 15:42:28 +00:00
Stefan Schmidt
37a7826a29 enable doxygen build for files in the channels/sip folder like reqresp_parser.c
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351707 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-20 12:59:11 +00:00
Richard Mudgett
f3c3de4c71 Misc minor fixes in reqresp_parser.c and chan_sip.c.
* Fix corner cases in get_calleridname() parsing and ensure that the
output buffer is nul terminated.

* Make get_calleridname() truncate the name it parses if the given buffer
is too small rather than abandoning the parse and not returning anything
for the name.  Adjusted get_calleridname_test() unit test to handle the
truncation change.

* Fix get_in_brackets_test() unit test to check the results of
get_in_brackets() correctly.

* Fix parse_name_andor_addr() to not return the address of a local buffer.
This function is currently not used.

* Fix potential NULL pointer dereference in sip_sendtext().

* No need to memset(calleridname) in check_user_full() or tmp_name in
get_name_and_number() because get_calleridname() ensures that it is nul
terminated.

* Reply with an accurate response if get_msg_text() fails in
receive_message().  This is academic in v1.8 because get_msg_text() can
never fail.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351618 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-19 23:17:31 +00:00
Kinsey Moore
46fce6837a Correct output of RTCP jitter statistics in SR and RR reports
Change the RTCP RR and SR generation code to convert Asterisk's internal jitter
statistics to be represented in RTP timestamp units based on the rate of the
codec in use instead of in seconds.

(closes issue ASTERISK-14530)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351611 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-19 22:36:02 +00:00
Jonathan Rose
5d9b4af4e2 Eliminates doubling the :port part of SIP Notify Message-Account headers.
This patch prevents the domain string from getting mangled during the initreqprep
step by moving the initialization to before its immediate use.  It also documents
this pitfall for the ast_sockaddr_stringify functions.

(issue ASTERISK-19057)
Reported by: Yuri
Review: https://reviewboard.asterisk.org/r/1678/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351559 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-19 21:46:31 +00:00
Joshua Colp
eb10c11063 Prevent crash when an SDP offer is received with an encrypted video stream when support for video is disabled and res_srtp is loaded.
(closes issue ASTERISK-19202)
Reported by: Catalin Sanda


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351504 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-19 21:11:12 +00:00
Matthew Jordan
177700450a Include iLBC source code for distribution with Asterisk
This patch includes the iLBC source code for distribution with Asterisk.
Clarification regarding the iLBC source code was provided by Google, and
the appropriate licenses have been included in the codecs/ilbc folder.

Review: https://reviewboard.asterisk.org/r/1675
Review: https://reviewboard.asterisk.org/r/1649

(closes issue: ASTERISK-18943)
Reporter: Leif Madsen
Tested by: Matt Jordan



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351450 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-18 20:54:37 +00:00
Stefan Schmidt
fde0147b3f The get_pai function in chan_sip.c didn't recognized a proper callerid name and
number from a P-Asserted-Identity cause the header parsing logic was wrong. 
Changing the parsing functions to the sip header parsing APIs in 
reqresp_parser.h solves this problem.

Review: https://reviewboard.asterisk.org/r/1673
Reviewed by: wdoekes2 and Mark Michelson



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351396 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-18 14:57:30 +00:00
Mark Michelson
37a8ff4dc8 Eliminate odd initialization of probation variable.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@351306 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-01-17 17:22:07 +00:00