summaryrefslogtreecommitdiff
path: root/res
AgeCommit message (Collapse)Author
2012-12-13Make generate_exchange_uuid() always return the passed ast_str pointer.Sean Bright
I changed this code earlier to return NULL if it wasn't able to generate a UUID, whereas the earlier code would always return the ast_str that was passed in. Switch back to returning the ast_str, only set it to the empty string instead if UUID generation fails. We still do a validity check later which will catch this and blow up if necessary. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@378000 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-13Use the UUID API to generate and validate UUIDs for res_calendar_exchange.Sean Bright
Currently the res_calendar_exchange module uses its own method of generating UUIDs using ast_random(). Now that we have a UUID API we should use that instead. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377974 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-13The UUID commit removed changes made in res_clialiases.cMark Michelson
This puts back in the changes that are designed to work around a memory leak fix in the CLI code. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377973 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-11Add UUID support to Asterisk.Mark Michelson
This provides a common API for dealing with unique identifiers. The API provides methods to create, parse, copy, and stringify UUIDs. An accompanying unit test is provided that tests all operations. (closes issue ASTERISK-20726) reported by Matt Jordan Review: https://reviewboard.asterisk.org/r/2217 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377846 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-11Fix crash that can occur if CLI registration fails for an aliased command.Mark Michelson
A recent memory leak fix in main/cli.c causes an ast_cli_entry's command field to be freed and NULLed if ast_cli_register() fails. res_clialiases was ignoring the return value of ast_cli_register() and was then passing the NULL command off to a a hash function. This resulted in a crash. The fix is not to ignore the erroneous return value. If ast_cli_register() fails, then we do not continue trying to process the current alias. ........ Merged revisions 377840 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 377842 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 377843 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377844 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-10Ensure ReceiveFax provides a CED tone via T.38Kinsey Moore
When using res_fax_digium, the T.38 CED tone was not being provided properly which would cause some incoming faxes to fail. This was not an issue with res_fax_spandsp since it does not strictly honor the send_ced flag and sends the CED tone whenever receiving a T.38 fax. (closes issue FAX-343) Reported-by: Benjamin Tietz Patch-by: Kinsey Moore ........ Merged revisions 377655 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 377656 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 377657 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377658 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-05res_srtp: Fix a crash caused by srtp_dealloc on an already dealloced sessionJonathan Rose
When srtp_create fails, the session may be dealloced or just not alloced. At the same time though, the session pointer might not be set to NULL in this process and attempting to srtp_dealloc it again will cause a segfault. This patch checks for failure of srtp_create and sets the session pointer to NULL if it fails. (closes issue ASTERISK-20499) Reported by: tootai Review: https://reviewboard.asterisk.org/r/2228/ ........ Merged revisions 377256 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 377261 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 377262 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377263 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-03Formatting fixesOlle Johansson
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@377035 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-12-03Formatting changesOlle Johansson
Found a large amount of missing {} in the code before patching in another branch git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@376998 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-20Added missing newlines to websocket ast_logs.David M. Lee
Without these newlines, log messages just continue tacking onto the same line, and do not flush immediately. ........ Merged revisions 376561 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@376562 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-11Remove a fixed size limitation for producing SDP and change how ICE support ↵Joshua Colp
is disabled by default. With ICE support enabled in chan_sip and a large number of interfaces on the system it was possible for the produced SDP to be truncated due to some fixed size buffers. These buffers have now been changed so they will dynamically grow as needed. ICE support is now also enabled by default in res_rtp_asterisk to provide a smoother experience for chan_motif users where it is required. To maintain the previous behavior in chan_sip it is no longer enabled by default there. (closes issue ASTERISK-20643) Reported by: coopvr ........ Merged revisions 376130 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@376131 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-08Fix a "set but not used" warning on newer gccs.Mark Michelson
Turns out the "helpful" setting of ms and res in this macro is completely useless after the timeout antipattern fix. If you're a new guy looking to write code, don't write a macro like this one. ........ Merged revisions 376087 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 376088 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 376089 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@376092 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-07Multiple revisions 375993-375994Mark Michelson
........ r375993 | mmichelson | 2012-11-07 11:01:13 -0600 (Wed, 07 Nov 2012) | 30 lines Fix misuses of timeouts throughout the code. Prior to this change, a common method for determining if a timeout was reached was to call a function such as ast_waitfor_n() and inspect the out parameter that told how many milliseconds were left, then use that as the input to ast_waitfor_n() on the next go-around. The problem with this is that in some cases, submillisecond timeouts can occur, resulting in the out parameter not decreasing any. When this happens thousands of times, the result is that the timeout takes much longer than intended to be reached. As an example, I had a situation where a 3 second timeout took multiple days to finally end since most wakeups from ast_waitfor_n() were under a millisecond. This patch seeks to fix this pattern throughout the code. Now we log the time when an operation began and find the difference in wall clock time between now and when the event started. This means that sub-millisecond timeouts now cannot play havoc when trying to determine if something has timed out. Part of this fix also includes changing the function ast_waitfor() so that it is possible for it to return less than zero when a negative timeout is given to it. This makes it actually possible to detect errors in ast_waitfor() when there is no timeout. (closes issue ASTERISK-20414) reported by David M. Lee Review: https://reviewboard.asterisk.org/r/2135/ ........ r375994 | mmichelson | 2012-11-07 11:08:44 -0600 (Wed, 07 Nov 2012) | 3 lines Remove some debugging that accidentally made it in the last commit. ........ Merged revisions 375993-375994 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 375995 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 376014 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@376015 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-05Refactor ast_timer_ack to return an error and handle the error in timer usersMatthew Jordan
Currently, if an acknowledgement of a timer fails Asterisk will not realize that a serious error occurred and will continue attempting to use the timer's file descriptor. This can lead to situations where errors stream to the CLI/log file. This consumes significant resources, masks the actual problem that occurred (whatever caused the timer to fail in the first place), and can leave channels in odd states. This patch propagates the errors in the timing resource modules up through the timer core, and makes users of these timers handle acknowledgement failures. It also adds some defensive coding around the use of timers to prevent using bad file descriptors in off nominal code paths. Note that the patch created by the issue reporter was modified slightly for this commit and backported to 1.8, as it was originally written for Asterisk 10. Review: https://reviewboard.asterisk.org/r/2178/ (issue ASTERISK-20032) Reported by: Jeremiah Gowdy patches: jgowdy-timerfd-6-22-2012.diff uploaded by Jeremiah Gowdy (license 6358) ........ Merged revisions 375893 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 375894 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 375895 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375896 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-11-04Only deref a reserved gateway session if we actually reserved oneMatthew Jordan
Its perfectly acceptable to have a gateway session unreserved when we go to first allocate one. Unreffing the reserved gateway session - when its NULL - will result in an assertion error. This problem was caught by the Asterisk Test Suite (once we had enough of the debugging flags enabled) ........ Merged revisions 375797 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 375798 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375799 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-31Fix an issue with res_http_websocket where the chan_sip WebSocket handler ↵Joshua Colp
could not be registered. On some systems the optional API support uses the GCC compiler attribute "weakref" to provide its functionality. This code changes the function names and prefixes "__" to the front. The res_http_websocket exports file did not take this into account, thereby not allowing those functions to be global and ultimately found. (closes issue ASTERISK-20631) Reported by: danjenkins ........ Merged revisions 375559 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375560 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-31Properly extract the Body information of an EWS calendar itemMatthew Jordan
Unlike all other calendar modules, res_calendar_ews fails to extract the Body information for a calendar item. This is due, in part, to a quirk in the schema in the XML - not only does a CalendarItem contain a Body element, but the CalendarItem exists as a descendant of a different Body element. The neon parser was erroneously skipping all Body elements. This patch fixes that by bypassing Body elements that are not a child of CalendarItem, and parsing the Body element out if it is a child. Note that the original patch by Terry Wilson only needed slight modifications to make it properly pull the Body information out; as such, while I've linked to the patch that I uploaded for Dmitry, I've attributed the patch to Terry. (closes issue ASTERISK-19738) Reported by: Dmitry Burilov Tested by: Dmitry Burilov patches: calendar_ews_body_2012_10_29.diff uploaded by Terry Wilson (license 6283) ........ Merged revisions 375528 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 375531 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 375532 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375533 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-17Change a few warnings to debug and the inverse.Walter Doekes
Remove the "RTP Read too short" warning for RTP keepalives. Remove the the warning about the application delimiter switch from pipe to comma. (You should've done this by now.) Make cdr_odbc report more when an insert fails. Make chan_sip warn less when the peer wants SRTP (and we don't) or sends a zero port to disable a media type. Review: https://reviewboard.asterisk.org/r/2167 (closes issue ASTERISK-20538) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375137 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-14Doxygen Updates - Title updateAndrew Latham
Update and extend the configuration_file group and enable linking to the resource. Update title that was left behind many years ago. (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@375003 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-08Disable ICE support by defaultMatthew Jordan
Since there are a number of legacy devices out there that fail to handle ICE candidates properly (which is a nice way of saying something much uglier), disable it by default. Support for ICE candidates can be enabled in rtp.conf using the icesupport setting. ........ Merged revisions 374676 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374677 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-08pjproject: Fix for Solaris builds. Do not undef s_addr.Matthew Jordan
pjproject, in order to solve build problems on Windows [1], undefines s_addr in one of it's headers that is included in res_rtp_asterisk.c. On Solaris s_addr is not a structure member, but defined to map to the real strucuture member, therefore when building on Solaris it's possible to get build errors like: [CC] res_rtp_asterisk.c -> res_rtp_asterisk.o In file included from /export/home/admin/asterisk-11-svn/include/asterisk/stun.h:29, from res_rtp_asterisk.c:51: /export/home/admin/asterisk-11-svn/include/asterisk/network.h: In function `inaddrcmp': /export/home/admin/asterisk-11-svn/include/asterisk/network.h:92: error: structure has no member named `s_addr' /export/home/admin/asterisk-11-svn/include/asterisk/network.h:92: error: structure has no member named `s_addr' res_rtp_asterisk.c: In function `ast_rtp_on_ice_tx_pkt': res_rtp_asterisk.c:706: warning: dereferencing type-punned pointer will break strict-aliasing rules res_rtp_asterisk.c:710: warning: dereferencing type-punned pointer will break strict-aliasing rules res_rtp_asterisk.c: In function `rtp_add_candidates_to_ice': res_rtp_asterisk.c:1085: error: structure has no member named `s_addr' make[2]: *** [res_rtp_asterisk.o] Error 1 make[1]: *** [res] Error 2 make[1]: Leaving directory `/export/home/admin/asterisk-11-svn' gmake: *** [_cleantest_all] Error 2 Unfortunately, in order to make this work, I also had to make sure pjproject only used the typdef pj_in_addr and not the struct pj_in_addr so that when building Asterisk I could "typedef struct in_addr pj_in_addr". It's possible then that the library and users of those interfaces in Asterisk have a different idea about the type of the argument, while on the surface it looks like they are all 32 bit big endian values. [1] http://trac.pjsip.org/repos/changeset/484 (issues ASTERISK-20366) Reported by: Ben Klang Tested by: Ben Klang, mjordan patches: 0001-pjproject-Fix-for-Solaris-builds.-Do-not-undef-s.patch uploaded by Shaun Ruffell (license 5417) ........ Merged revisions 374642 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374643 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-06Handle capability stanzas that fail to provide node or version informationMatthew Jordan
While XEP-0115 states that the node and ver attributes are both required, some devices fail to provide either field. Prior to this patch, failure to provide the node or ver attribute would cause a crash in res_xmpp. While failing to provide the node or ver attribute is technically invalid, since this information is not utilized by Asterisk except for reporting purposes, for interoperability reasons, we continue to process the capability stanza anyways. (closes issue ASTERISK-20495) Reported by: Martin W Tested by: Martin W patches: 20495.patch uploaded by Martin W (license #6434) ........ Merged revisions 374622 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374623 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-06Update documentation for MessageSend application/command's From field for XMPPMatthew Jordan
When using the channel technology agnostic application/AMI command MessageSend, the "From" field is technically optional for the SIP channel driver. However, if being sent by the XMPP resource module (either res_xmpp or res_jabber), the "From" field is necessary, and must correspond to a defined account. This patch updates the documentation for this application/AMI command to reflect this. (closes issue ASTERISK-20405) Reported by: Leif Madsen ........ Merged revisions 374611 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374612 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04Fix DBDelTree error codes for AMI, CLI and AGIDavid M. Lee
The AMI DBDelTree command will return Success/Key tree deleted successfully even if the given key does not exist. The CLI command 'database deltree' had a similar problem, but was saved because it actually responded with '0 database entries removed'. AGI had a slightly different error, where it would return success if the database was unavailable. This came from confusion about the ast_db_deltree retval, which is -1 in the event of a database error, or number of entries deleted (including 0 for deleting nothing). * Changed some poorly named res variables to num_deleted * Specified specific errors when calling ast_db_deltree (database unavailable vs. entry not found vs. success) * Fixed similar bug in AGI database deltree, where 'Database unavailable' results in successful result (closes issue AST-967) Reported by: John Bigelow Review: https://reviewboard.asterisk.org/r/2138/ ........ Merged revisions 374426 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 374427 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 374428 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374429 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-04Check for presence of buddy in info/dinfo handlersMatthew Jordan
The res_jabber resource module uses the ASTOBJ library for managing its ref counted objects. After calling ASTOBJ_CONTAINER_FIND to locate a buddy object, the pointer to the object has to be checked to see if the buddy existed. Prior to this patch, the buddy object was not checked for NULL; with this patch in both aji_client_info_handler and aji_dinfo_handler the pointer is checked before used and, if no buddy object was found, the handlers return an error code. This patch does not take the approach that our JID can be used to log in from another resource. If that approach is desired, an improvement could be made to this patch to create the buddy on the fly. This patch seeks only to prevent Asterisk from crashing. FYI: In Asterisk 11+, you really should be using res_xmpp. It does not have this problem, as it moved to the astobj2 library. Note that multiple people have proposed patches for this issue; the patch being committed here is based on those. (closes issue ASTERISK-19532) Reported by: Karsten Wemheuer Tested by: Byron Clark patches: fix-jabber uploaded by Karsten Wemheuer (license #5930) xmpp_no_crash_with_ejabberd.patch uploaded by Byron Clark (license #6157) (closes issue ASTERISK-19557) Reported by: ulugutz ........ Merged revisions 374335 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 374336 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 374337 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374338 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-02Fix a variety of ref counting issuesMatthew Jordan
This patch resolves a number of ref leaks that occur primarily on Asterisk shutdown. It adds a variety of shutdown routines to core portions of Asterisk such that they can reclaim resources allocate duringd initialization. Review: https://reviewboard.asterisk.org/r/2137 ........ Merged revisions 374177 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 374178 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 374196 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374197 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-01Doxygen CleanupAndrew Latham
Start adding configuration file linking and pages. Add module loading doxygen block. Breaking up commits to keep it easy to track (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374165 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-10-01Add support for retrieving engine specific settings using the speech API and ↵Joshua Colp
from dialplan. (closes issue ASTERISK-17136) Reported by: kenner git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374096 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-28Include channel uniqueid in "AsyncAGI" and "AGIExec" events.Richard Mudgett
* Added AMI event documentation for AsyncAGI and AGIExec events. (closes issue ASTERISK-20318) Reported by: Dan Cropp Patches: res_agi_patch.txt (license #6422) patch uploaded by Dan Cropp modified for trunk. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374075 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-28res_jabber: Remove CLI command 'jabber test'Jonathan Rose
The opinion of development was that it is both improper to have Matt's personal email address used in the source and that the command wouldn't be useful without it. (closes issue AST-467) Reported by: Malcolm Davenport ........ Merged revisions 374032 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 374045 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 374059 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374060 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-28Reset hangup flags on channels created through messages and cleanup globalsBrent Eagles
in res_xmpp on unload. This patch fixes an issue where hangup flags were not being reset on a channel, affecting subsequent use of that channel. The patch also adds some additional cleanup to res_xmpp to fix an issue with reloading the module. (closes ASTERISK-20360) Reported by: Noah Engelberth Tested by: beagles Review: https://reviewboard.asterisk.org/r/2134/ ........ Merged revisions 374019 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@374020 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-28Update documentation to make it explicit that "stream file" will not restart ↵Joshua Colp
musiconhold. (issue ASTERISK-17367) Reported by: oej ........ Merged revisions 373989 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 373990 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 373991 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373992 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-27Make res_http_websocket an optional dependency on supported platforms for ↵Joshua Colp
chan_sip. (closes issue ASTERISK-20439) Reported by: sruffell Patches: 0001-chan_sip-websocket-support-is-an-optional-API.patch uploaded by sruffell (license 5417) ........ Merged revisions 373914 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373915 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25res_agi: async_agi responsiveness improvement on datastore problemsJonathan Rose
This patch changes get_agi_cmd so that the return can be checked to differentiate between an empty list success and something that triggered an error. This in turn allows launch_asyncagi to detect these errors and break free from the command processing loop so that the async agi can be ended more cleanly (closes issue ASTERISK-20109) Reported by: Jeremiah Gowdy Patches: jgowdy-7-9-2012.diff uploaded by Jeremiah Gowdy (license 6358) (Modified by me to fix some logical issues and apply to trunk) Review: https://reviewboard.asterisk.org/r/2117/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373608 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-25Fix an issue where a caller to ast_write on a MulticastRTP channel would ↵Joshua Colp
determine it failed when in reality it did not. When sending RTP packets via multicast the amount of data sent is stored in a variable and returned from the write function. This is incorrect as any non-zero value returned is considered a failure while a return value of 0 is success. For callers (such as ast_streamfile) that checked the return value they would have considered it a failure when in reality nothing went wrong and it was actually a success. The write function for the multicast RTP engine now returns -1 on failure and 0 on success, as it should. (closes issue ASTERISK-17254) Reported by: wybecom ........ Merged revisions 373550 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 373551 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 373552 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373553 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-24Fix an issue with H.264 format attribute comparison and fix an issue with ↵Joshua Colp
improper SDP being produced. The H.264 format attribute module compares two format attribute structures to determine if they are compatible or not. In some instances it was possible for this check to determine that both structures were incompatible when they actually should be considered compatible. This check has now been made even more permissive by assuming that if no attribute information is available the two structures are compatible. If both structures contain attribute information a base level comparison of the H.264 IDC value is done to see if they are compatible or not. The above issue uncovered a secondary issue in chan_sip where the SDP being produced would be incorrect if the formats were considered incompatible. This has now been fixed by checking that all information required to produce the SDP is available instead of assuming it is. (closes issue ASTERISK-20464) Reported by: Leif Madsen ........ Merged revisions 373413 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373414 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-24res_rtp_asterisk: Make TURN and STUN server configurations consistent.Brent Eagles
This patch removes the turnport configuration property and changes the turnaddr property to be a combined host[:port] configuration string. The patch also modifies the documentation in the example configuration to reflect the property changes and adds some additional text indicating how the STUN port is configured. (closes issue ASTERISK-20344) Reported by: beagles Tested by: beagles Review: https://reviewboard.asterisk.org/r/2111/ ........ Merged revisions 373403 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373404 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-22Doxygen Updates Janitor WorkAndrew Latham
* Whitespace, doc-blocks, spelling, case, missing and incorrect tags. * Add cleanup to Makefile for the Doxygen configuration update * Start updating Doxygen configuration for cleaner output * Enable inclusion of configuration files into documentation * remove mantisworkflow... * update documentation README * Add markup to Tilghman's email and talk with him about updating his email, he knows... * no code changes on this commit other than the mentioned Makefile change (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373384 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-21Doxygen Updates - janitor workAndrew Latham
Doxygen updates including mistakes, misspellings, missing parameters, updates for Doxygen style. Some missing txt file links are removed but their content or essense will be included in some later updates. A majority of the txt files were removed in the 1.6 era but never noted. The HR and EXTREF are simple changes that make the documentation more compatable with more versions of Doxygen. Further updates coming. (issue ASTERISK-20259) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373330 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-20Add support for DTLS-SRTP to res_rtp_asterisk and chan_sip.Joshua Colp
As mentioned on the review for this, WebRTC has moved towards choosing DTLS-SRTP as the mechanism for key exchange for SRTP. This commit adds support for this but makes it available for normal SIP clients as well. Testing has been done to ensure that this introduces no regressions with existing behavior and also that it functions as expected. Review: https://reviewboard.asterisk.org/r/2113/ ........ Merged revisions 373229 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373234 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-20When trying to unload res_curl.so, warn about all dependent modules.Sean Bright
Before this, attempting to unload res_curl.so would warn you about the first module it found that was dependent. We now warn about all of the loaded modules instead. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@373203 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-12res_xmpp: Fix a segfault caused by bodyless messagesJonathan Rose
(closes issue ASTERISK-20361) Reported by: Noah Engelberth Review: https://reviewboard.asterisk.org/r/2108/ ........ Merged revisions 372984 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372985 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-10Deprecate chan_gtalk, chan_jingle, and res_jabberKinsey Moore
chan_gtalk, chan_jingle, and res_jabber are now deprecated in favor of using chan_motif and res_xmpp. They are a feature-equivalent replacement and are written to be more easily maintainable. (closes issue ASTERISK-20298) Review: https://reviewboard.asterisk.org/r/2082/ Reported-by: Leif Madsen ........ Merged revisions 372795 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372796 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-10res_rtp_asterisk: Eliminate "type-punned pointer" build warning.David M. Lee
Removes "res_rtp_asterisk.c:706: warning: dereferencing type-punned pointer will break strict-aliasing rules" warning from the build on 32-bit platforms. The problem is that 'size' was referenced aliased to both (pj_size_t *) and (pj_ssize_t *). Now just make a copy of size that is the right type so there isn't any pointer aliasing happening. It also adds comments and asserts regarding what looks like an inappropriate use of pj_sock_sendto, but is actually totally fine. (closes issue ASTERISK-20368) Reported by: Shaun Ruffell Tested by: Michael L. Young Patches: 0001-res_rtp_asterisk-Eliminate-type-punned-pointer-build.patch uploaded by Shaun Ruffell (license 5417) slightly modified by David M. Lee. ........ Merged revisions 372777 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372787 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-07Fix parallel make for res_asterisk_rtp.David M. Lee
Fixes a build regression introduced in r369517 "Add support for ICE/STUN/TURN in res_rtp_asterisk and chan_sip." [1]. [1] http://svnview.digium.com/svn/asterisk?view=revision&revision=369517 When compiling asterisk in parallel like: $ make -j 10 It's possible to get errors like the following: .pjlib-util-test-x86_64-unknown-linux-gnu.depend:120: *** missing separator. Stop. make[4]: *** [depend] Error 2 make[3]: *** [dep] Error 1 make[2]: *** [/home/sruffell/asterisk-working/res/pjproject/pjnath/lib/libpjnath-x86_64-unknown-linux-gnu.a] Error 2 make[3]: warning: jobserver unavailable: using -j1. Add `+' to parent make rule. This is because the build system is trying to build each of the libraries in pjproject in parallel. Now the build will build pjproject in a single job and link the results into res_asterisk_rtp. Parallel builds, on one test system, saves ~1.5 minutes from a default Asterisk build: Single job: $ git clean -fdx >/dev/null && time ( ./configure >/dev/null 2>&1 && make >/dev/null 2>&1 ) real 2m34.529s user 1m41.810s sys 0m15.970s Parallel make: $ git clean -fdx >/dev/null && time ( ./configure >/dev/null 2>&1 && make -j10 >/dev/null 2>&1 ) real 1m2.353s user 2m39.120s sys 0m18.850s (closes issue ASTERISK-20362) Reported by: Shaun Ruffel Patches: 0001-res_asterisk_rtp-Fix-build-error-when-using-parallel.patch uploaded by Shaun Ruffel (License #5417) ........ Merged revisions 372609 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372610 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-05Multiple revisions 372327-372328Richard Mudgett
........ r372327 | rmudgett | 2012-09-05 12:33:11 -0500 (Wed, 05 Sep 2012) | 15 lines Fix RTP/RTCP read error message confusion. The RTP/RTCP read error message can report "fail: success" when the read failure is because of an ICE failure. * Changed __rtp_recvfrom() to generate a PJ ICE message when ICE fails. * Changed RTP/RTCP read error message to indicate an unspecified error when errno is zero. (closes issue ASTERISK-20288) Reported by: Joern Krebs Patches: jira_asterisk_20288_err_msg.patch (license #5621) patch uploaded by rmudgett (modified) ........ r372328 | rmudgett | 2012-09-05 12:35:20 -0500 (Wed, 05 Sep 2012) | 1 line Fix coding guidelines issue with a recent commit. ........ Merged revisions 372327-372328 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372329 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-05Re-fix sending unnegotiated payloads during a P2P RTP bridge.Mark Michelson
The previous fix still would look in the static_RTP_PT table, which is inappropriate since we specifically want to find a codec that has been negotiated. (closes issue ASTERISK-20296) reported by NITESH BANSAL Patches: codec_negotiation.patch Uploaded by NITESH BANSAL (License #6418) ........ Merged revisions 372311 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372319 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-05Fix breakage caused by last merge. Missing a variable for 11 and trunk.Michael L. Young
........ Merged revisions 372266 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372267 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-09-05Fix Incrementing Sequence Number For Retransmitted DTMF End PacketsMichael L. Young
In Asterisk 1.4+, a fix was put in place to increment the sequence number for retransmitted DTMF end packets. With the introduction of the RTP engine API in 1.8, the sequence number was no longer being incremented. This patch fixes this regression as well as cleans up a few lines that were not doing anything. (closes issue ASTERISK-20295) Reported by: Nitesh Bansal Tested by: Michael L. Young Patches: 01_rtp_event_seq_num.patch uploaded by Nitesh Bansal (license 6418) asterisk-20295-dtmf-fix-cleanup.diff uploaded by Michael L. Young (license 5026) Review: https://reviewboard.asterisk.org/r/2083/ ........ Merged revisions 372185 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 372198 from http://svn.asterisk.org/svn/asterisk/branches/10 ........ Merged revisions 372199 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372200 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2012-08-31Prevent local RTP bridges from sending inappropriate formats to participants.Mark Michelson
A change for Asterisk 11 caused a check for failure to incorrectly check the return value. This resulted in the possibility of transmitting media that a party had not negotiated. If this media happened to be G.729, then this could potentially result in one-way audio if no G.729 translators are installed. (closes issue ASTERISK-20296) reported by NITESH BANSAL ........ Merged revisions 372118 from http://svn.asterisk.org/svn/asterisk/branches/11 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@372119 65c4cc65-6c06-0410-ace0-fbb531ad65f3