2008-01-31 Russell Bryant * Asterisk 1.4.18 released. 2008-01-31 23:10 +0000 [r101601] Russell Bryant * main/translate.c, main/file.c: Fix a couple of places where ast_frfree() was not called on a frame that came from a translator. This showed itself by g729 decoders not getting released. Since the flag inside the translator frame never got unset by freeing the frame to indicate it was no longer in use, the translators never got destroyed, and thus the g729 licenses were not released. (closes issue #11892) Reported by: xrg Patches: 11892.diff uploaded by russell (license 2) Tested by: xrg, russell 2008-01-31 21:00 +0000 [r101531] Mark Michelson * res/res_monitor.c: 1. Prevent the addition of an extra '/' to the beginning of an absolute pathname. 2. If ast_monitor_change_fname is called and the new filename is the same as the old, then exit early and don't set the filename_changed field in the monitor structure. Setting it in this case was causing ast_monitor_stop to erroneously delete them. (closes issue #11741) Reported by: garlew Tested by: putnopvut 2008-01-31 19:52 +0000 [r101482] Jason Parker * channels/chan_sip.c, channels/chan_iax2.c: Solaris compat fixes for struct in_addr funkiness. Issue #11885, patch by snuffy. 2008-01-31 19:30 +0000 [r101480] Steve Murphy * main/pbx.c: closes issue #11845; that's the one where there's a 1004 byte cdr leak with every AMI Redirect to a zap channel 2008-01-31 19:17 +0000 [r101413-101433] Russell Bryant * channels/chan_agent.c: Add more missing locking of the agents list ... * channels/chan_agent.c: Move the locking from find_agent() into the agent dialplan function handler to ensure that the agent doesn't disappear while we're looking at it. * channels/chan_agent.c: Add missing locking to the find_agent() function. 2008-01-30 15:41 +0000 [r101222] Joshua Colp * main/slinfactory.c: Fix an issue where if a frame of higher sample size preceeded a frame of lower sample size and ast_slinfactory_read was called with a sample size of the combined values or higher a crash would happen. (closes issue #11878) Reported by: stuarth 2008-01-30 15:34 +0000 [r101219] Jason Parker * configs/extensions.conf.sample: Change default config to use descending channel order of groups, rather than ascending. Fixes a potential source of confusion in glare-type situations. Issue 11875, reported by JimVanM. 2008-01-30 15:23 +0000 [r101216] Mark Michelson * apps/app_queue.c: Fix a logic error with regards to autofill. Prior to this change, it was possible for a caller to go out of turn if autofill were enabled and callers ahead in the queue were attempting to call a member. This change fixes this. 2008-01-30 11:20 +0000 [r101152] Olle Johansson * channels/chan_sip.c: Stop musiconhold on attended transfer. (closes issue #11872) Reported by: gareth Patches: svn-101018.patch uploaded by gareth (license 208) 2008-01-29 23:50 +0000 [r101080] Dwayne M. Hubbard * build_tools/make_version: updated build_tools to handle the autotag directory structure changes; changes related to BE-353. Patch by The Russell and reviewed by The Me. 2008-01-29 23:02 +0000 [r100973-101035] Mark Michelson * apps/app_queue.c: Remove a memory leak from updating realtime queues * apps/app_queue.c: Fixing an erroneous return value returned when attempting to pause or unpause a queue member fails. Fixes BE-366, thanks to John Bigelow for writing the patch. 2008-01-29 17:57 +0000 [r100934] Joshua Colp * apps/app_mixmonitor.c: Don't forget to record the channel so we know whether it is bridged or not later. (closes issue #11811) Reported by: slavon 2008-01-29 17:43 +0000 [r100932] Russell Bryant * main/Makefile: Fix the last couple of issues related to building from a path that contains spaces. (closes issue #11834) 2008-01-29 17:41 +0000 [r100930] Jason Parker * channels/misdn_config.c: Initialize an array to 0s if config option not specified. (closes issue #11860) Patches: misdn_get_config.v1.diff uploaded by IgorG (license 20) 2008-01-29 17:21 +0000 [r100882-100922] Russell Bryant * Makefile: Use GNU make magic instead of shell magic to escape spaces in the working directory. (related to issue #11834) * Makefile: Fix building Asterisk when the working path has spaces in it. (closes issue #11834) Reported by: spendergrass Patched by: me 2008-01-29 16:10 +0000 [r100835] Jason Parker * channels/chan_zap.c: Allow zap groups above 30 to work properly. (closes issue #11590) Reported by: tbsky 2008-01-29 10:36 +0000 [r100793] Christian Richter * channels/chan_misdn.c: fixed potential segfault in misdn show channels CLI command 2008-01-29 08:26 +0000 [r100740] Olle Johansson * channels/chan_sip.c: (closes issue #11736) Reported by: MVF Patches: bug11736-2.diff uploaded by oej (license 306) Tested by: oej, MVF, revolution (russellb: This was the showstopper for the release.) 2008-01-28 21:02 +0000 [r100675] Tilghman Lesher * main/pbx.c: WaitExten didn't handle AbsoluteTimeout properly (went to 't' instead of 'T') 2008-01-28 20:55 +0000 [r100673] Mark Michelson * channels/chan_vpb.cc, UPGRADE.txt: Undoing the deprecation of chan_vpb. It is alive and well. 2008-01-28 20:42 +0000 [r100672] Jason Parker * apps/app_voicemail.c: When using ODBC_STORAGE, make sure we put greeting files into the database like we do with the others. Issue #11795 Reported by: dimas Patches: vmgreet.patch uploaded by dimas (license 88) 2008-01-28 18:34 +0000 [r100626-100629] Russell Bryant * channels/chan_sip.c: For some reason, the use of this strdupa() is leading to memory corruption on freebsd sparc64. This trivial workaround fixes it. (closes issue #10300, closes issue #11857, reported by mattias04 and Home-of-the-Brave) * res/res_features.c: Fix a crash in ast_masq_park_call() (issue #11342) Reported by: DEA Patches: res_features-park.txt uploaded by DEA (license 3) 2008-01-28 18:23 +0000 [r100624] Jason Parker * channels/chan_zap.c: Correct a comment which made little/no sense. 2008-01-28 17:15 +0000 [r100581] Russell Bryant * main/channel.c, channels/chan_local.c, include/asterisk/channel.h: Make some deadlock related fixes. These bugs were discovered and reported internally at Digium by Steve Pitts. - Fix up chan_local to ensure that the channel lock is held before the local pvt lock. - Don't hold the channel lock when executing the timing function, as it can cause a deadlock when using chan_local. This actually changes the code back to be how it was before the change for issue #10765. But, I added some other locking that I think will prevent the problem reported there, as well. 2008-01-27 21:59 +0000 [r100465] Tilghman Lesher * main/rtp.c, channels/chan_mgcp.c, main/cdr.c, channels/chan_misdn.c, main/dnsmgr.c, channels/chan_sip.c, channels/chan_h323.c, include/asterisk/sched.h, main/file.c, pbx/pbx_dundi.c, channels/chan_iax2.c: When deleting a task from the scheduler, ignoring the return value could possibly cause memory to be accessed after it is freed, which causes all sorts of random memory corruption. Instead, if a deletion fails, wait a bit and try again (noting that another thread could change our taskid value). (closes issue #11386) Reported by: flujan Patches: 20080124__bug11386.diff.txt uploaded by Corydon76 (license 14) Tested by: Corydon76, flujan, stuarth` 2008-01-25 22:32 +0000 [r100418] Mark Michelson * channels/chan_vpb.cc, UPGRADE.txt: Deprecating chan_vpb. It is now preferred that users of Voicetronix products use chan_zap in combination with their zaptel drivers. 2008-01-25 21:24 +0000 [r100378] Jason Parker * channels/chan_sip.c: This would have never been true, since we're passing (sizeof(req.data) - 1) as the len to recvfrom(). 2008-01-24 21:57 +0000 [r100264] Kevin P. Fleming * include/asterisk/app.h: make these macros not assume that the only other field in the structure is 'argc'... this is true when someone uses AST_DECLARE_APP_ARGS, but it's perfectly reasonable to define your own structure as long as it has the right fields 2008-01-24 17:22 +0000 [r100164] Russell Bryant * main/asterisk.c: Update main Asterisk copyright info to 2008 2008-01-24 16:41 +0000 [r100138] Jason Parker * main/acl.c: Fix compilation on Solaris. (closes issue #11832) Patches: bug-11832.diff uploaded by snuffy (license 35) 2008-01-23 21:07 +0000 [r99977-99978] Olle Johansson * channels/chan_sip.c: Second attempt. Don't change invitestate when receiving 18x messages in CANCEL state. (issue #11736) Reported by: MVF Patch by oej. * channels/chan_sip.c: Make sure we don't cancel destruction on calls in CANCEL state, even if we get 183 while waiting for answer on our CANCEL. (issue #11736) Reported by: MVF Patches: bug11736.txt uploaded by oej (license 306) Tested by: MVF 2008-01-23 20:25 +0000 [r99975] Mark Michelson * apps/app_externalivr.c: Fixing a typo. 2008-01-23 17:46 +0000 [r99923] Russell Bryant * apps/app_chanspy.c: ChanSpy issues a beep when it starts at the beginning of a list of channels to potentially spy on. However, if there were no matching channels, it would beep at you over and over, which is pretty annoying. Now, it will only beep once in the case that there are no channels to spy on, but it will still beep again once it reaches the beginning of the channel list again. (closes issue #11738, patched by me) 2008-01-23 16:18 +0000 [r99878] Mark Michelson * channels/chan_sip.c: These flag tests were illogical. They were testing sip_peer flags on a sip_pvt. Thanks to Russell for helping to get this odd problem figured out. 2008-01-23 04:31 +0000 [r99718-99777] Tilghman Lesher * apps/app_voicemail.c: When we reset the password via an external command, we should also reset the password stored in the in-memory list, too (otherwise it doesn't really take effect). (closes issue #11809) Reported by: davetroy Patches: fix_externpass.diff uploaded by davetroy (license 384) * res/res_odbc.c: Oops, should have checked for a NULL obj, here, too * main/acl.c: Just confirmed that all current platforms need this header file 2008-01-22 20:56 +0000 [r99652] Olle Johansson * channels/chan_sip.c: Thanks to Russell's education I realize that BUFSIZ has changed since I learned the C language over 20 years ago... Resetting chan_sip to the size of BUFSIZ that I expected in my old head to avoid to heavy memory allocations on some systems. 2008-01-22 20:34 +0000 [r99643] Tilghman Lesher * main/acl.c: Fix the defines for OS X (and Solaris, too) 2008-01-22 17:41 +0000 [r99592-99594] Olle Johansson * channels/chan_local.c, res/res_features.c, channels/chan_agent.c, apps/app_followme.c: Add more dependencies on chan_local and add a note to the description of chan_local so that people don't disable it in menuselect just to clean up. * apps/app_dial.c: Add dependency on chan_local to app_dial. Dial still runs without chan_local, but will be missing forwarding functionality. 2008-01-22 16:54 +0000 [r99540] Tilghman Lesher * main/acl.c: Ensure that we can get an address even when we don't have a default route. (closes issue #9225) Reported by: junky Patches: 20080122__bug9225.diff.txt uploaded by Corydon76 (license 14) Tested by: oej, loloski, sergee 2008-01-22 15:08 +0000 [r99501] Olle Johansson * channels/chan_sip.c: Cleaning up some documentation that led to confusion in a bug report 2008-01-21 23:55 +0000 [r99426] Mark Michelson * channels/chan_local.c: Fixing an issue wherein monitoring local channels was not possible. During a channel masquerade, the monitors on the two channels involved are swapped. In 99% of the cases this results in the desired effect. However, if monitoring a local channel, this caused the monitor which was on the local channel to get moved onto a channel which is immediately hung up after the masquerade has completed. By swapping the monitors prior to the masquerade, we avoid the problem by tricking the masquerade into placing the monitor back onto the channel where we want it. During the investigation of the issue, the channel's monitor was the only thing that was swapped in such a manner which did not make sense to have done. All other variable swapping made sense. 2008-01-21 18:11 +0000 [r99341] Tilghman Lesher * res/res_odbc.c, configs/res_odbc.conf.sample, include/asterisk/res_odbc.h: Permit the user to specify number of seconds that a connection may remain idle, which fixes a crash on reconnect with the MyODBC driver. (closes issue #11798) Reported by: Corydon76 Patches: 20080119__res_odbc__idlecheck.diff.txt uploaded by Corydon76 (license 14) Tested by: mvanbaak 2008-01-21 16:01 +0000 [r99301] Joshua Colp * channels/chan_sip.c: Bump the buffer size for Via headers up to 512. There are some exceptionally large Via headers out there. (closes issue #11783) Reported by: ofirroval 2008-01-19 10:05 +0000 [r99187] Russell Bryant * main/slinfactory.c: Fix a couple of memory leaks with frame handling. Specifically, ast_frame_free() needed to be called on the frame that came from the translator to signed linear. 2008-01-18 22:57 +0000 [r99127] Joshua Colp * include/asterisk/channel.h: Remove the __ in front of the unused variable. This causes some compilers to freak out. 2008-01-18 21:37 +0000 [r99079-99081] Russell Bryant * include/asterisk/translate.h, main/frame.c: Revert adding the packed attribute, as it really doesn't make sense why that would do any good. Fix the real bug, which is to do the check to see if the frame came from a translator at the beginning of ast_frame_free(), instead of at the end. This ensures that it always gets checked, even if none of the parts of the frame are malloc'd, and also ensures that we aren't looking at free'd memory in the case that it is a malloc'd frame. (closes issue #11792, reported by explidous, patched by me) * include/asterisk/translate.h: Since we're relying on the offset between the frame and the beginning of the translator pvt struct, set the packed attribute to make sure we get to the right place. (potential fix for issue #11792) 2008-01-18 17:13 +0000 [r99032] Terry Wilson * res/res_features.c: This should at least temporarily fix a problem where the 't' Dial option is incorrectly passed to the transferee when built-in attended transfers are used. There is still a problem with 'T', but better to fix some problems than no problems while we work on it. (closes issue #7904) Reported by: k-egg Patches: transfer-fix-b14-r97657.diff uploaded by sergee (license 138) Tested by: sergee, otherwiseguy 2008-01-17 23:42 +0000 [r99007-99014] Pari Nannapaneni * configs/cdr.conf.sample: doh! revert a revert of a revert (changed by mistake in 99010) * main/manager.c, configs/cdr.conf.sample: missed that one while reverting * main/manager.c: reverting 99001 - We need the Max-Age for extending the life of cookie mansession_id 2008-01-17 22:37 +0000 [r99004] Russell Bryant * main/frame.c, channels/chan_iax2.c, include/asterisk/frame.h: Have IAX2 optimize the codec translation path just like chan_sip does it. If the caller's codec is in our codec list, move it to the top to avoid transcoding. (closes issue #10500) Reported by: stevedavies Patches: iax-prefer-current-codec.patch uploaded by stevedavies (license 184) iax-prefer-current-codec.1.4.patch uploaded by stevedavies (license 184) Tested by: stevedavies, pj, sheldonh 2008-01-17 21:31 +0000 [r99001] Kevin P. Fleming * main/manager.c: we should only send the Set-Cookie header to the browser on the first response after creating a manager session, not on every response (doing so causes the browser to clear any local cookies it may have associated with the session) 2008-01-17 16:19 +0000 [r98991] Jason Parker * configs/zapata.conf.sample: Add a clarification about the immediate= option of zapata.conf Issue 11784, patch by klaus3000. 2008-01-16 22:36 +0000 [r98982] Russell Bryant * .cleancount, include/asterisk/channel.h: Add an unused pointer to the ast_channel struct. This makes the ast_channel structure retain the same size as it had in previous 1.4 releases. Also, all of the offsets for members in the structure are still the same (except for the two pointers that got replaced for the new spy/whisper architecture.) 2008-01-16 20:34 +0000 [r98966-98973] Joshua Colp * .cleancount: Bump up cleancount due to previous commit that changed the channel structure. * apps/app_chanspy.c, apps/app_mixmonitor.c, main/rtp.c, main/channel.c, apps/app_meetme.c, include/asterisk/audiohook.h (added), main/Makefile, include/asterisk/chanspy.h (removed), include/asterisk/channel.h, main/audiohook.c (added): Replace current spy architecture with backport of audiohooks. This should take care of current known spy issues. * channels/chan_iax2.c: Add missing NULLs at end of two ast_load_realtimes. (closes issue #11769) Reported by: tequ Patches: chaniax.patch uploaded by dimas (license 88) 2008-01-16 17:20 +0000 [r98964] Mark Michelson * channels/chan_local.c: Fix a deadlock in chan_local in local_hangup. There was contention because the local_pvt was held and it was attempting to lock a channel, which is the incorrect locking order. (closes issue #11730) Reported by: UDI-Doug Patches: 11730.patch uploaded by putnopvut (license 60) Tested by: UDI-Doug 2008-01-16 15:08 +0000 [r98951-98960] Joshua Colp * main/dial.c: Introduce a lock into the dialing API that protects it when destroying the structure. (closes issue #11687) Reported by: callguy Patches: 11687.diff uploaded by file (license 11) * main/rtp.c: Add two more SDP names for ulaw and alaw. (closes issue #11777) Reported by: tootai * channels/chan_sip.c: Don't drop the old record route information when dealing with packets related to a reinvite. (closes issue #11545) Reported by: kebl0155 Patches: reinvite-patch.txt uploaded by kebl0155 (license 356) * build_tools/menuselect-deps.in, configure, include/asterisk/autoconfig.h.in, codecs/codec_speex.c, configure.ac, makeopts.in: Add autoconf logic for speexdsp. Later versions use a separate library for some things so we need to use it if present in codec_speex. (closes issue #11693) Reported by: yzg 2008-01-15 23:50 +0000 [r98943-98946] Russell Bryant * channels/chan_sip.c: Change a buffer in check_auth() to be a thread local dynamically allocated buffer, instead of a massive buffer on the stack. This fixes a crash reported by Qwell due to running out of stack space when building with LOW_MEMORY defined. On a very related note, the usage of BUFSIZ in various places in chan_sip is arbitrary and careless. BUFSIZ is a system specific define. On my machine, it is 8192, but by definition (according to google) could be as small as 256. So, this buffer in check_auth was 16 kB. We don't even support SIP messages larger than 4 kB! Further usage of this define should be avoided, unless it is used in the proper context. * main/rtp.c, include/asterisk/translate.h, main/frame.c, main/translate.c, main/abstract_jb.c, channels/chan_iax2.c, codecs/codec_zap.c, include/asterisk/frame.h: Commit a fix for some memory access errors pointed out by the valgrind2.txt output on issue #11698. The issue here is that it is possible for an instance of a translator to get destroyed while the frame allocated as a part of the translator is still being processed. Specifically, this is possible anywhere between a call to ast_read() and ast_frame_free(), which is _a lot_ of places in the code. The reason this happens is that the channel might get masqueraded during this time. During a masquerade, existing translation paths get destroyed. So, this patch fixes the issue in an API and ABI compatible way. (This one is for you, paravoid!) It changes an int in ast_frame to be used as flag bits. The 1 bit is still used to indicate that the frame contains timing information. Also, a second flag has been added to indicate that the frame came from a translator. When a frame with this flag gets released and has this flag, a function is called in translate.c to let it know that this frame is doing being processed. At this point, the flag gets cleared. Also, if the translator was requested to be destroyed while its internal frame still had this flag set, its destruction has been deffered until it finds out that the frame is no longer being processed. Admittedly, this feels like a hack. But, it does fix the issue, and I was not able to think of a better solution ... 2008-01-15 20:08 +0000 [r98894-98934] Joshua Colp * channels/chan_sip.c: Based on the boundary found move over the correct amount. (closes issue #11750) Reported by: tasker * channels/chan_sip.c: Accept "; boundary=" not just ";boundary=" in the multipart mixed content type. (closes issue #11750) Reported by: tasker 2008-01-14 20:59 +0000 [r98849] Mark Michelson * apps/app_voicemail.c: Adding in appropriate unlocks for the locks I added. Thanks to joetester on IRC for pointing this out. 2008-01-14 17:38 +0000 [r98774] Russell Bryant * main/translate.c: Revert a change that introduces an unacceptable performance hit and is causing memory leaks ... (from rev 97973) 2008-01-14 16:35 +0000 [r98733-98737] Mark Michelson * apps/app_queue.c: Fixing another compilation error. I'm a bit off today :( * apps/app_queue.c: Oops. Last commit had compilation error. * apps/app_queue.c: Adding explicit defaults for missing options to init_queue. This is necessary because if a user either removes or comments one of these options and reloads their queues, the option will not reset to its default, instead maintaining the value from prior to the reload. Thanks to John Bigelow for pointing this error out to me. 2008-01-12 00:05 +0000 [r98467] Tilghman Lesher * res/res_odbc.c: Add a connection timeout attribute, as that was what was intended with the login timeout, but ODBC divides it up into 2 different timeouts. (Closes issue #11745) 2008-01-11 22:46 +0000 [r98390] Russell Bryant * pbx/pbx_dundi.c: Fix up setting the EID on BSD based systems. (closes issue #11646) Reported by: caio1982 Patches: dundi_osx_eid6.diff.txt uploaded by caio1982 (license 22) dundi_osx_eid6-1.4.diff uploaded by caio1982 (license 22) Tested by: caio1982, mvanbaak 2008-01-11 21:28 +0000 [r98372] Pari Nannapaneni * main/http.c: Comment explaining how to force browser to always read some html files from server. 2008-01-11 19:51 +0000 [r98317-98325] Joshua Colp * main/rtp.c: If the incoming RTP stream changes codec force the bridge to break if the other side does not support it. (closes issue #11729) Reported by: tsearle Patches: new_codec_patch_udiff.patch uploaded by tsearle (license 373) * res/res_agi.c: If the channel is hungup during RECORD FILE send a result code of -1 to be uniform with everything else. (closes issue #11743) Reported by: davevg Patches: res_agi.diff uploaded by davevg (license 209) 2008-01-11 19:10 +0000 [r98315] Mark Michelson * main/channel.c: Properly report the hangup cause as no answer when someone does not answer (closes issue #10574, reported by boch, patched by moy) 2008-01-11 18:25 +0000 [r98266] Tilghman Lesher * codecs/gsm/Makefile: Add another exception (which doesn't work) for -march optimization flag. Reported by: thomasmebes Patch by: tilghman (Closes issue #11563) 2008-01-11 18:25 +0000 [r98265] Russell Bryant * doc/security.txt, main/asterisk.c, configure, include/asterisk/autoconfig.h.in, main/Makefile, configure.ac, makeopts.in: Backport the ability to set the ToS bits on Linux when not running as root. Normally, we would not backport features into 1.4, but, I was convinced by the justification supplied by the supplier of this patch. He pointed out that this patch removes a requirement for running as root, thus reducing the potential impacts of security issues. (closes issue #11742) Reported by: paravoid Patches: libcap.diff uploaded by paravoid (license 200) 2008-01-11 17:22 +0000 [r98219] Joshua Colp * apps/app_followme.c: Ensure the return value of ast_bridge_call is passed back up as the application return value. This is needed for transfers to function so the PBX core knows to continue execution. (closes issue #10327) Reported by: kkiely 2008-01-11 15:52 +0000 [r98164] Tilghman Lesher * channels/chan_sip.c: Back out changes from revision 97077, since it wasn't perfect 2008-01-11 03:39 +0000 [r97976-98082] Russell Bryant * main/frame.c: Fix samples vs. length calculations for g722 * main/translate.c: Simplify this code with a suggestion from Luigi on the asterisk-dev list. Instead of using is16kHz(), implement a format_rate() function. * main/translate.c: Fix various timing calculations that made assumptions that the audio being processed was at a sample rate of 8 kHz. 2008-01-10 23:08 +0000 [r97973] Tilghman Lesher * channels/chan_sip.c, main/translate.c: 1) When we get a translated frame out, clone it, because if the translator pvt is freed before we use the frame, bad things happen. 2) Getting a failure from ast_sched_delete means that the schedule ID is currently running. Don't just ignore it. (Closes issue #11698) 2008-01-10 21:57 +0000 [r97925] Mark Michelson * apps/app_voicemail.c: Let us leave a voicemail for ourself if we have logged into VoiceMailMain and chosen to leave a message. (closes issue #11735, reported and patched by jamessan) 2008-01-10 21:37 +0000 [r97849-97889] Steve Murphy * pbx/ael/ael_lex.c, pbx/Makefile, pbx/ael/ael.flex: Applied the same fixes for ael.flex as was done in 97849 for ast_expr2.fl; overrode the normally generate yyfree func with our own version that checks the pointer for non-null before passing to free(). Also takes care of a little problem with 2.5.33 and the use of the __STDC_VERSION__ macro. * main/ast_expr2.fl, main/Makefile, main/ast_expr2f.c: This is a fix for 2 things: a problem Terry was having in OSX with null pointers, which was my fault, as I probably forgot to run the sed script last time I made mods. So, I moved the fix into the flex input itself. Then, I found when I used flex 2.5.33, that it was using __STDC_VERSION__, and that's not real good; so I added back in a DIFFERENT sed script to fix that little mess. Tested everything, a couple different ways. Hope I did no harm, at the least. 2008-01-10 20:12 +0000 [r97847] Jason Parker * include/asterisk/frame.h: Fix a comment that is no longer true. 2008-01-10 16:19 +0000 [r97734-97753] Russell Bryant * pbx/pbx_kdeconsole.h (removed), configs/modules.conf.sample, pbx/kdeconsole_main.cc (removed): Remove other remnants of pbx_kdeconsole * pbx/pbx_kdeconsole.cc (removed), build_tools/menuselect-deps.in, configure, include/asterisk/autoconfig.h.in, configure.ac, makeopts.in: Remove pbx_kdeconsole from the tree. It hasn't worked in ages, and nobody has complained. (closes issue #11706, reported by caio1982) 2008-01-10 15:07 +0000 [r97697] Joshua Colp * funcs/func_groupcount.c: Don't try to copy the category from the group if no category exists. (closes issue #11724) Reported by: IgorG Patches: group_count.v1.patch uploaded by IgorG (license 20) 2008-01-09 23:01 +0000 [r97640-97645] Russell Bryant * pbx/pbx_gtkconsole.c: Strip terminal sequences from the verbose messages * pbx/pbx_gtkconsole.c: Make pbx_gtkconsole build ... but doesn't actually load on my system still (related to issue #11706) 2008-01-09 20:28 +0000 [r97618-97622] Jason Parker * main/cli.c: Correctly display a message if a command could not be found. Also fix a comment which may have led to this happening. Issue 11718, reported by kshumard. * main/cli.c: Fix some locking and return value funkiness. We really shouldn't be unlocking this lock inside of a function, unless we locked it there too. 2008-01-09 18:48 +0000 [r97575] Mark Michelson * apps/app_queue.c: Part 2 of app_queue doxygen improvements. Some smaller functions this time 2008-01-09 18:02 +0000 [r97529] Russell Bryant * res/res_features.c: Fix saying the parking space number to the caller doing the parking ... 2008-01-09 17:21 +0000 [r97491] Kevin P. Fleming * codecs/codec_zap.c: report the same message whether Zaptel does not have transcoder support loaded or no transcoders were found 2008-01-09 16:44 +0000 [r97489] Philippe Sultan * channels/chan_gtalk.c: Set the caller id within the gtalk_alloc function. As underlined in issue #10437 by Josh, we need to prevent a possible memory leak. We only set the name part of the caller id, the number part is not relevant when dealing with JIDs. Closes issue #11549. 2008-01-09 16:11 +0000 [r97450] Joshua Colp * apps/app_meetme.c: Don't do conferencing totally in Zaptel if Monitor is running on the channel. (closes issue #11709) Reported by: BigJimmy Patches: patch-meetmerec uploaded by BigJimmy (license 371) 2008-01-09 15:43 +0000 [r97410-97448] Kevin P. Fleming * channels/chan_zap.c: pass the right variable to get an error string... oops * channels/chan_zap.c: add error number output to ioctl failure messages to help with debugging 2008-01-09 00:44 +0000 [r97350] Tilghman Lesher * main/cli.c, main/editline/readline.c: Allow filename completion on zero-length modules, remove a memory leak, remove a file descriptor leak, and make filename completion thread-safe. Patched and tested by tilghman. (Closes issue #11681) 2008-01-09 00:17 +0000 [r97206-97308] Mark Michelson * apps/app_queue.c: use the \retval doxygen command properly * apps/app_queue.c: Part 1 of N of adding doxygen comments to app_queue. I picked some of the most common functions used (which also happen to be some the biggest/ugliest functions too) to document first. I'm pretty new to doxygen so criticism is welcome. * apps/app_queue.c: Some coding guidelines-related cleanup 2008-01-08 20:48 +0000 [r97195] Joshua Colp * channels/chan_mgcp.c: Fix various DTMF issues in chan_mgcp. (closes issue #11443) Reported by: eferro Patches: dtmf_control_hybrid-inband-mode.patch uploaded by eferro (license 337) 2008-01-08 20:47 +0000 [r97194] Tilghman Lesher * main/autoservice.c, main/utils.c: Increase constants to where we're less likely to hit them while debugging. (Closes issue #11694) 2008-01-08 20:42 +0000 [r97192] Mark Michelson * apps/app_voicemail.c: Making some changes designed to not allow for a corrupted mailstream for a vm_state. 1. Add locking to the vm_state retrieval functions so that no linked list corruption occurs. 2. Make sure to always grab the persistent vm_state when mailstream access is necessary. 3. Correct an incorrect return value in the init_mailstream function. (closes issue #11304, reported by dwhite) 2008-01-08 19:53 +0000 [r97093-97152] Joshua Colp * funcs/func_groupcount.c: If no group has been provided to the GROUP_COUNT dialplan function then use the first one specific to the channel. (closes issue #11077) Reported by: m4him * apps/app_queue.c: Make app_queue calls work with directed pickup. (closes issue #11700) Reported by: jbauer 2008-01-08 18:02 +0000 [r97077] Tilghman Lesher * main/asterisk.c, channels/chan_sip.c: Apply multiple crash fixes, found in issue #11386, but not completely closing that issue. 2008-01-07 20:47 +0000 [r96884-96932] Russell Bryant * configs/extensions.conf.sample, /: Merged revisions 96931 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r96931 | russell | 2008-01-07 14:46:22 -0600 (Mon, 07 Jan 2008) | 2 lines Change misery.digium.com to pbx.digium.com ........ * res/res_smdi.c: Don't crash if something happens when setting up an SMDI interface and it gets destroyed before the SMDI port handling thread gets created. 2008-01-07 14:34 +0000 [r96797-96815] Philippe Sultan * res/res_jabber.c: Indentation fix, makes the code easier to read * res/res_jabber.c: Compute the base64 value over the [authzid]\0authcid\0password string, thus excluding the trailing NULL byte. This change has already been committed to trunk, see #11644. 2008-01-05 02:09 +0000 [r96644] Russell Bryant * main/devicestate.c: Don't pass an empty string as the device name. 2008-01-04 23:03 +0000 [r96575] Tilghman Lesher * main/devicestate.c: Fix the problem of notification of a device state change to a device with a '-' in the name. Could probably do with a better fix in trunk, but this bug has been open way too long without a better solution. Reported by: stevedavies Patch by: tilghman (Closes issue #9668) 2008-01-04 22:55 +0000 [r96573] Jason Parker * res/res_features.c: Properly continue in the dialplan if using PARKINGEXTEN and the slot is full. Issue 11237, patch by me. 2008-01-04 19:27 +0000 [r96525] Tilghman Lesher * channels/chan_sip.c: If you change the bindaddr in sip.conf to a non-bound address and reload, sip goes kablooie. Reported and patched by: one47 (Closes issue #11535) 2008-01-04 16:19 +0000 [r96394-96449] Russell Bryant * channels/chan_zap.c: Make use of the temporary channel pointer while the pvt is unlocked. (closes issue #11675) Reported by: flefoll Patches: chan_zap.c.patch-store-owner-before-unlock uploaded by flefoll (license 244) * channels/chan_iax2.c: Don't crash if the iax2 pvt structure has been destroyed before we get to this point (closes issue #11672, reported by snuffy, patched by me) 2008-01-03 21:37 +0000 [r96318] Tilghman Lesher * res/res_config_pgsql.c: Missed initialization caused crash. Reported and fixed by: tiziano (Closes issue #11671) 2008-01-03 12:12 +0000 [r96198-96199] Christian Richter * channels/chan_misdn.c: make sure frame is completely clean, before we send it to asterisk as DTMF. If we don't make it clean, it happens that one way audio occurs.. * channels/chan_misdn.c: when overlapdial was used and no number was dialed, the call was dropped, now we just jump into the s extension, which makes a lot more sense. 2008-01-02 23:46 +0000 [r96102] Mark Michelson * apps/app_queue.c: We need to reset the membername to NULL on each iteration of this loop, otherwise the result is that multiple members can have the same name, since the variable was not reset on each iteration of the loop. 2008-01-02 22:14 +0000 [r96020-96024] Russell Bryant * pbx/pbx_config.c: Convert locks of the contexts list in pbx_config to the appropriate rdlock or wrlock * pbx/pbx_dundi.c: pbx_dundi only needs a rdlock on the contexts list. * apps/app_macro.c: app_macro only needs a rdlock on the contexts list. 2008-01-02 Russell Bryant * Asterisk 1.4.17 released. 2008-01-02 20:24 +0000 [r95946] Joshua Colp * channels/chan_sip.c: Allocate a SIP refer structure when performing a transfer using BYE with Also so that the transfer information is properly stored. (AST-2008-028) (closes issue #11637) Reported by: greyvoip 2008-01-02 17:51 +0000 [r95890] Mark Michelson * apps/app_queue.c: A change to improve the accuracy of queue logging in the case where a member does not answer during the specified timeout period. Prior to this change, there was a small chance that the member name recorded in this case would be blank. Also prior to this change, if using the ringall strategy, if no one answered the call during the specified timeout, the member name listed in the queue log would randomly be one of the members that was rung. (closes issue #11498, reported and tested by hloubser, patched by me) 2007-12-31 23:43 +0000 [r95577] Mark Michelson * main/pbx.c: Avoiding a potentially bad locking situation. ast_merge_contexts_and_delete writelocks the conlock, then calls ast_hint_extension, which attempts to readlock the same lock. Recursion with read-write locks is dangerous, so the inner lock needs to be removed. I did this by copying the "guts" of ast_hint_extension into ast_merge_contexts_and_delete (sans the extra lock). (this change is inspired by the locking problems seen in issue #11080, but I have no idea if this is the problematic area experienced by the reporters of that issue) 2007-12-31 20:27 +0000 [r95470] Tilghman Lesher * funcs/func_env.c: Allow the default "0" to be returned if the STAT fails (Closes issue #11659) 2007-12-28 18:24 +0000 [r95191] Russell Bryant * channels/chan_sip.c: Remove duplicate increment of the header count in the add_header() function. (closes issue #11648) Reported by: makoto Patch provided by sergee, committed patch by me, inspired by comments from putnopvut 2007-12-28 00:16 +0000 [r95095] Mark Michelson * apps/app_queue.c: I found a bug while browsing the queue code and managed to reproduce it in a small setup. If a queue uses the ringall strategy, it was possible through unfortunate coincidence for a single member at a given penalty level to make app_queue think that all members at that penalty level were unavailable and cause the members at the next penalty level to be rung. With this patch, we will only move to the next penalty level if ALL the members at a given penalty level are unreachable. 2007-12-27 21:40 +0000 [r95024] Russell Bryant * main/channel.c: Don't report a syntax error when an empty string is passed to ast_get_group. Just return 0. (closes issue #11540) Reported by: tzafrir Patches: group_empty.diff uploaded by tzafrir (license 46) -- slightly changed by me 2007-12-27 20:09 +0000 [r94977] Mark Michelson * main/io.c: Fixing a typo in a comment. 2007-12-27 17:32 +0000 [r94905-94924] Joshua Colp * channels/chan_h323.c: Include types.h in chan_h323 as without it it can not be compiled on some operating systems like FreeBSD to name one. (closes issue #11585) Reported by: sobomax Patches: chan_h323.c.diff uploaded by sobomax (license 359) * channels/chan_sip.c: Use ast_strlen_zero to see if our_contact is set or not on the dialog. It is possible for it to be a pointer to NULL. (closes issue #11557) Reported by: FuriousGeorge 2007-12-27 15:16 +0000 [r94828-94831] Russell Bryant * main/pbx.c: Now that the contexts lock is a read/write lock, it should not be locked here in ast_hint_state_changed(). This makes it get locked recursively which now causes a deadlock. (closes issue #11080, thanks to callguy for the access to a deadlocked machine) * include/asterisk/translate.h, main/translate.c: Use the constant that I really meant to use here ... * main/translate.c: Change ast_translator_best_choice() to only pay attention to audio formats. This fixes a problem where Asterisk claims that a translation path can not be found for channels involving video. (closes issue #11638) Reported by: cwhuang Tested by: cwhuang Patch suggested by cwhuang, with some additional changes by me. 2007-12-27 01:01 +0000 [r94824] Kevin P. Fleming * main/manager.c: make this comment explain the situation in an even more explicit fashion 2007-12-26 20:43 +0000 [r94808] Tilghman Lesher * main/manager.c: Workaround for what is probably a glibc bug (but we'll see this crop up again and again, if we don't add the workaround). Reported by: rolek Patch by: tilghman (Closes issue #11601, closes issue #11426) 2007-12-26 19:04 +0000 [r94789-94801] Russell Bryant * main/autoservice.c: Just in case the AST_FLAG_END_DTMF_ONLY flag was already set before starting autoservice, remember it and ensure that the channel has the same setting when autoservice gets stopped. (pointed out by d1mas, patched up by me) * main/autoservice.c: When a channel is in autoservice, mark a flag on the channel that says that we only care about the END of a digit. That way, no magic digit emulation stuff will happen when all we're doing is queueing up END frames. * res/res_features.c: Don't try to send a parked call back to itself. (closes issue #11622, reported by djrodman, patched by me) * main/autoservice.c: Don't store DTMF BEGIN frames while a channel is in autoservice. It's just going to make ast_read() do a lot of extra work when the channel comes back out of autoservice. (closes issue #11628, patched by me) * Makefile: List include/asterisk/version.h as a .PHONY target because we want the commands listed for this target to be executed regardless of whether the file exists or not. This fixes having the version not up to date when running from svn. (closes issue #11619, reported by plack, fixed by me) 2007-12-25 02:27 +0000 [r94769] Joshua Colp * channels/chan_sip.c: file says... build on the builders. 2007-12-24 19:36 +0000 [r94763-94767] Tilghman Lesher * main/channel.c: Race: we need to wait to queue a NewChannel event until after the channel is inserted into the channel list. The reason is because some manager users immediately queue requests from the channel when they see that event and are confused when Asterisk reports no such channel. (Closes issue #11632) * channels/chan_sip.c: More deadlock avoidance code (this time between sip_monitor and sip_hangup) Reported by: apsaras Patch by: tilghman (Closes issue #11413) * channels/chan_sip.c: Another bit of bad logic in realtime_peer Reported by: dimas Patch by: dimas (Closes issue #11631) 2007-12-23 01:21 +0000 [r94660] Tilghman Lesher * channels/chan_sip.c: Argh... I suppose third time's the charm. 2007-12-21 20:21 +0000 [r94468-94543] Mark Michelson * apps/app_voicemail.c: Bunch of coding guidelines cleanup * apps/app_voicemail.c: Better quota support for using IMAP storage voicemail (closes issue #11415, reported by jaroth) (closes issue #11152, reported by selsky) Patch provided by jaroth * apps/app_voicemail.c: The mail_copy c-client function does not expect a full imap mailbox string, just the name of the mailbox. (closes issue #11419, reported and patched by jaroth, with additional patchwork from me) * main/dial.c: Since we are freeing list elements within a list traversal, we need to use the safe traversal and remove the item from the list before freeing it. (closes issue 11612, reported by dtyoo) 2007-12-21 16:37 +0000 [r94466] Russell Bryant * main/pbx.c, include/asterisk/pbx.h: Convert the contexts lock to a read/write lock to resolve a deadlock. This has a nice side benefit of improving performance. :) (closes issue #11609) (closes issue #11080) 2007-12-21 16:11 +0000 [r94420-94464] Mark Michelson * apps/app_queue.c: Removing a debug message I accidentally just committed * main/say.c, apps/app_queue.c: Fixing Portuguese syntax for saying dates and times. Also some coding guidelines cleanup. (closes issue #11599, reported and patched by caio1982, coding guidelines cleanup by me) 2007-12-21 15:07 +0000 [r94418] Tilghman Lesher * main/asterisk.c: Fix for restart-as-user problem reported via the -dev list 2007-12-20 Russell Bryant * Asterisk 1.4.16.2 released. 2007-12-20 20:22 +0000 [r94215-94256] Russell Bryant * /, channels/chan_iax2.c: Merged revisions 94255 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r94255 | russell | 2007-12-20 14:21:41 -0600 (Thu, 20 Dec 2007) | 5 lines Fix another potential seg fault ... (closes issue #11606) Reported by: dimas ........ * channels/chan_zap.c: Fix a deadlock in d-channel handling in chan_zap. This deadlock was introduced by the fix to ensure that channels are properly locked when handling channel variables. There were sections of this code where the channel pvt was locked before the channel lock, when in fact it _must_ be the other way around. (closes issue #11582) Reported by: bugi * /: Blocked revisions 94214 via svnmerge ........ r94214 | russell | 2007-12-20 11:29:11 -0600 (Thu, 20 Dec 2007) | 2 lines Fix a couple of places where it's possible to dereference a NULL pointer. ........ 2007-12-19 23:02 +0000 [r94122] Mark Michelson * res/res_monitor.c: Sox versions 13.0.0 and newer do not have "soxmix" and instead use sox -m. res_monitor needs to use this if the user does not have soxmix. (closes issue #11589, reported by amessina, patch inspired by amessina but with a flourish from me) 2007-12-19 22:48 +0000 [r94077] Russell Bryant * configure, include/asterisk/autoconfig.h.in, configure.ac: Check for the existence of the soxmix application on the target platform and have the result available in autoconfig.h. (part of issue #11589) 2007-12-19 Russell Bryant * Asterisk 1.4.16.1 released. 2007-12-19 17:29 +0000 [r93955] Joshua Colp * channels/chan_iax2.c: Make the 1.4 builders happy, ensure var is NULL. 2007-12-19 17:04 +0000 [r93949] Tilghman Lesher * channels/chan_iax2.c: Avoid segfault in chan_iax when peer isn't defined (Closes issue #11602) 2007-12-18 22:42 +0000 [r93764] Jason Parker * channels/chan_skinny.c: FreeBSD also does not have byte swap functions. Issue 11586, patch by sobomax. 2007-12-18 Russell Bryant * Asterisk 1.4.16 released. 2007-12-18 18:45 +0000 [r93668-93676] Tilghman Lesher * /, channels/chan_sip.c, channels/chan_iax2.c: Merged revisions 93667 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r93667 | tilghman | 2007-12-18 12:23:06 -0600 (Tue, 18 Dec 2007) | 2 lines Fixing AST-2007-027 (Closes issue #11119) ........ 2007-12-18 17:02 +0000 [r93625] Mark Michelson * main/channel.c: Rework deadlock avoidance used in ast_write, since it meant that agent channels which were being monitored had one audio file recorded and one empty audio file saved. (closes issue #11529, reported by atis patched by me) 2007-12-17 22:56 +0000 [r93381-93420] Jason Parker * main/translate.c: What was I thinking when I wrote this masterpiece? -1 + 1 = 0.. who woulda thunk it?. 2007-12-17 22:28 +0000 [r93377] Joshua Colp * main/utils.c: Do not try to access information about a lock when printing out a trylock attempt. It is possible for the lock that it references to no longer be valid. This would have caused segfaults or deadlocks. (issue #BE-263) (closes issue #11080) Reported by: callguy (closes issue #11100) Reported by: callguy 2007-12-17 21:12 +0000 [r93336] Tilghman Lesher * include/asterisk/time.h: Today is tomorrow's yesterday, and yesterday's tomorrow is today, and tomorrow's tomorrow is the day after tomorrow, so who cares if you recycle anyway? If this confuses you, that's nothing compared to what this fixes. ;-) 2007-12-17 19:53 +0000 [r93291] Mark Michelson * apps/app_voicemail.c: We need to create the directory for a voicemail user even if they are using IMAP storage since greetings are stored in the filesystem. (closes issue #11388, reported by spditner, patch by me inspired by a patch by spditner) 2007-12-17 18:05 +0000 [r93250] Joshua Colp * channels/chan_zap.c: If a call is received with a called number IE containing nothing go to the 's' extension. (closes issue #9099) Reported by: kb1_kanobe2 Patches: 20070906__9099.diff.txt uploaded by Corydon76 (license 14) 2007-12-17 07:21 +0000 [r93183] Kevin P. Fleming * funcs/Makefile, codecs/Makefile, cdr/Makefile, pbx/Makefile, res/Makefile, channels/Makefile, formats/Makefile: fix some copy-and-paste leftovers 2007-12-17 07:15 +0000 [r93182] Olle Johansson * channels/chan_mgcp.c, channels/chan_zap.c, channels/chan_sip.c, apps/app_queue.c, channels/chan_iax2.c: Issue 11574: Add dependencies on res_monitor and res_features. I wonder if Asterisk can run at all without res_features. My guess is that there's propably a lot of more modules and the core that depends on it. Reported by: caio1982 (closes issue #11574) 2007-12-17 06:44 +0000 [r93180] Kevin P. Fleming * formats, Makefile, codecs/Makefile, funcs, apps/Makefile, configure, cdr/Makefile, build_tools/prep_tarball, makeopts.in, formats/Makefile, pbx, res, channels, funcs/Makefile, codecs, include/asterisk/autoconfig.h.in, build_tools/make_version, apps, configure.ac, Makefile.moddir_rules, build_tools/prep_moduledeps (removed), res/Makefile, pbx/Makefile, cdr, channels/Makefile: In http://lists.digium.com/pipermail/asterisk-dev/2007-December/031145.html, rizzo brought up some issues related to the way that the metadata required for menuselect and the rest of the build system is extracted from the source files. Since I had a few hours to kill on an airplane today, I decided to improve this situation... so now the system caches the extracted metadata and uses it to build the menuselect 'tree' as much as it can. The result of this is that when a single source file is changed, only the metadata for that file needs to be extracted again, and the rest is used from the cache files. I also reduced the number of forked processes required to do the metadata extraction; it was actually possible to do most of what we needed in the Makefiles themselves without using any shell scripts at all! On my laptop, these changes resulted in an 80% decrease in the time required for the 'menuselect.makeopts' automatic check to occur after editing a single source file. While doing this work I also cleaned up a few minor things in the Makefiles, adding a check for 'awk' to the configure script and changed all remaining places we use 'grep' or 'awk' to use the ones found by the configure script, and changed the 'prep_tarball' script to build the menuselect metadata so that tarballs of Asterisk will include it and won't require the user to wait while it is extracted after unpacking. 2007-12-14 17:36 +0000 [r93000] Russell Bryant * main/config.c: There are a lot of existing systems that #include non-existent files. So, to make the transition to treating this as an error a bit less painless, just issue a huge error message for now. Then, later, we can reinstate the code that treats it as a failure. (Thanks to philippel for the feedback) 2007-12-14 15:16 +0000 [r92937] Joshua Colp * channels/chan_sip.c: Up the length of the format on the SIP channel since it can now be rather long. (closes issue #11552) Reported by: francesco_r 2007-12-14 15:05 +0000 [r92934] Christian Richter * channels/chan_misdn.c: fixed the sequencing of WAITING_4DIGS state setting and overlap_task thread starting. 2007-12-14 15:01 +0000 [r92933] Tilghman Lesher * res/res_agi.c: Change help documentation to match actual behavior (FAILURE vs FAILED). Reported by: angeloxx-sir Patch by: tilghman (Closes issue #11548) 2007-12-14 01:24 +0000 [r92875] Mark Michelson * include/asterisk/lock.h: When compiling with DETECT_DEADLOCKS, don't spam the CLI with messages about possible deadlocks. Instead just print the intended single message every five seconds. (closes issue 11537, reported and patched by dimas) 2007-12-13 21:28 +0000 [r92815] Tilghman Lesher * channels/chan_zap.c: Properly initialize polarity statuses, so that they are detected properly. Reported by: julianjm Patch by: julianjm (Closes issue #10238) 2007-12-13 20:13 +0000 [r92809] Jason Parker * main/pbx.c: Make application help text a little more clear about the use of extensions in a filename. 2007-12-13 20:03 +0000 [r92803-92807] Mark Michelson * apps/app_voicemail.c: Prevent another potential fd leak * apps/app_voicemail.c: Prevent a possible fd leak. 2007-12-13 00:11 +0000 [r92696] Jason Parker * main/config.c, channels/chan_sip.c, channels/chan_h323.c, channels/chan_iax2.c: If a typo is found in a config file, we previous continued on with what was already loaded. We do not want to do this (see bug below for details). This makes it so that if a [ is found without a ], the entire config will fail, and nothing in it will be loaded. Isue #10690. 2007-12-12 22:00 +0000 [r92656] Kevin P. Fleming * codecs/codec_zap.c: emit a warning message when we drop a G.729B CNG frame destined for the transcoder 2007-12-12 21:15 +0000 [r92617] Jason Parker * apps/app_meetme.c: Don't increment user count until after name has been recorded (if enabled). Issue 11048, tested by pep. 2007-12-12 19:40 +0000 [r92556] Russell Bryant * res/res_features.c: resolve compiler warning 2007-12-12 17:46 +0000 [r92510] Mark Michelson * res/res_features.c: Correctly detect where a dynamic feature was activated. Before this patch, the channel which initiated the bridge was always assumed to have been the one which activated the dynamic feature. This patch corrects this. (closes issue #11529, reported and patched by nic_bellamy) 2007-12-12 16:52 +0000 [r92463] Tilghman Lesher * configure, include/asterisk/autoconfig.h.in, configure.ac: Test directly for the API that fixed AST-2007-026, to ensure that older versions of PostgreSQL are no longer acceptable. (Closes issue #11526) 2007-12-12 16:08 +0000 [r92443] Mark Michelson * apps/app_queue.c: Removing an unused variable. 2007-12-11 19:51 +0000 [r92363] Joshua Colp * main/global_datastores.c: Fix potential memory leak with the dialed interfaces list if another memory allocation fails. (closes issue #11507) Reported by: eliel Patches: global_datastores.c.patch uploaded by eliel (license 64) 2007-12-11 17:42 +0000 [r92323] Mark Michelson * apps/app_queue.c: Fixing autofill to be more accurate. Specifically, if calls ahead of the current caller were ringing members (but not yet bridged) there could be available members and waiting callers who would not get matched up. The member availability checker was correctly determining the number of available members in this scenario, but the queue itself did not parallelly reflect this status on the pending calls. This commit corrects the issue. (closes issue #11459, reported by equissoftware, patched by me) 2007-12-10 16:36 +0000 [r92204] Joshua Colp * main/rtp.c: Add G729A as another possible payload name for G729. Some devices use this instead of G729, which is perfectly normal since the payload number itself is defined and can't be used by anything else so the name doesn't matter that much. (closes issue #11483) Reported by: revolution Patches: rtp.diff uploaded by revolution (license 346) 2007-12-10 16:29 +0000 [r92202] Mark Michelson * apps/app_queue.c: If there are no members in a queue, then the loop where the datastore for detecting duplicate dialed numbers will be skipped, meaning the datastore isn't created. This means that when we try to free it, there's a crash. This stops that crash from occurring. (closes issue #11499, reported by slavon, patched by eliel) 2007-12-10 16:13 +0000 [r92200] Joshua Colp * channels/chan_sip.c: It is possible for nativeformats to contain more then one codec, so print out multiple ones. (closes issue #11366) Reported by: ovi 2007-12-10 14:04 +0000 [r92158] Olle Johansson * channels/chan_sip.c: Avoid reinvite race situations with two Asterisks trying to reinvite each other in 1.4 and trunk. This patch implements support for the 491 error code that Asterisk 1.4 generates on situations where we get an incoming INVITE and already has one in progress. Thanks to mavetju for reporting and to Raj Jain for an excellent explanation of the problem. Patch by myself. Tested with 8 Asterisk servers connected to each other in a training network. Closes issue #10481 2007-12-07 23:29 +0000 [r91890] Jason Parker * main/dsp.c: We need to make sure we free the input frame if we return a different frame in ast_dsp_process. Issue 11273, pointed out by dimas, with a patch by eliel. 2007-12-07 22:30 +0000 [r91870] Kevin P. Fleming * codecs/codec_zap.c: even though Asterisk explicitly requests that endpoints using G.729 do *not* use Annex B (silence detection and comfort noise generation) some do anyway; the transcoder card interface does not currently work properly with CNG frames, so trim off the CNG before sending the data 2007-12-07 21:24 +0000 [r91777-91830] Russell Bryant * main/utils.c: Make the lock protecting each thread's list of locks it currently holds recursive. I think that this will fix the situation where some people have said that "core show locks" locks up the CLI. (related to issue #11080) * include/asterisk/lock.h: Fix another bug in the DEBUG_THREADS code. The ast_mutex_init() function had the mutex attribute object marked as static. This means that multiple threads initializing locks at the same time could step on each other and end up with improperly initialized locks. (found when tracking down locking issues related to issue #11080) * include/asterisk/lock.h: I love fixing lock related errors in the lock debugging code. That's about as ironic as it gets in Asterisk programming land. Anyway, I spotted this bug while trying to track down why systems are locking up and acting weird in issue #11080. The mutex attribute object was marked as static in this function when it should not have been. * apps/app_dial.c: * Add channel locking around datastore operations that expect the channel to be locked. * Document why we don't record Local channels in the dialed interfaces list. * Remove the dialed variable as it isn't needed. * Restructure some code for clarity and coding guidelines stuff * apps/app_queue.c: * Add channel locking around datastore operations that expect the channel to be locked. * Document why we don't record Local channels in the dialed interfaces list. * Handle memory allocation failure. * Remove the dialed variable, as it wasn't actually needed. * Tweak some formatting to conform to coding guidelines. * main/autoservice.c: * Add a bit more of a verbose comment as to why a hangup frame needs to be queued up if autoservice gets a NULL return from ast_read(). * Make the process of queueing the hangup frame more efficient by putting the frame where it is going to end up and avoiding some locking and extra memory allocations and freeing. 2007-12-07 15:39 +0000 [r91737] Mark Michelson * main/autoservice.c: Hangups that happen during autoservice were not processed appropriately. This is because a hangup actually causes a NULL frame to be received, not a hangup frame. Queueing a hangup if we receive a NULL frame during autoservice corrects this problem (closes issue #11467, reported by jmls, patched by me) 2007-12-07 02:51 +0000 [r91675-91693] Russell Bryant * apps/app_dial.c: Don't unlock the dialed_interfaces list until we're done messing with the iterator. * apps/app_dial.c, apps/app_queue.c: Allow dialing local channels from Queue() and Dial() again. There was a slight flaw in the code to prevent call forwards from looping that caused this problem. (related to issue #11486) * apps/app_queue.c: Fix in an issue in the call forwarding handling code that was causing crashes on every call into a queue. I'm not entirely sure about the logic in this part of the code, so I want to look at it some more tomorrow. However, this makes it safe and keeps it from crashing. (closes issue #11486, reported by adamg, patched by me) 2007-12-07 00:52 +0000 [r91637] Tilghman Lesher * main/rtp.c: At the end of a call, when we're reporting, RTCP may already be partially torn down, so check for NULL dereference Reported by: blitzrage Patch by: tilghman (Closes issue #11450) 2007-12-06 20:25 +0000 [r91541] Mark Michelson * apps/app_voicemail.c: IMAP storage did not honor the maxmsg setting in voicemail.conf, and it also had the possibility of crashing if a user had more than 256 messages in their voicemail. This patch kills two birds with one stone by adding maxmsg support and also setting a hard limit on the number of messages at 255 so that the crashes cannot happen. (closes issue #11101, reported by Skavin, patched by me) 2007-12-06 19:11 +0000 [r91501] Russell Bryant * main/loader.c, include/asterisk/module.h: Add a new module flag to indicate that a build sum is present. Modules built against older Asterisk 1.4 headers will now load properly with just a warning indicating that they are old and may cause problems. (patch by paravoid) 2007-12-06 16:49 +0000 [r91439-91450] Joshua Colp * main/udptl.c: Fix various in the udptl implementation. It could return empty modem frames, have an incorrect sequence number on packets, and display the wrong sequence number in the debug messages. (closes issue #11228) Reported by: Cache Patches: udptl-4.patch uploaded by dimas (license 88) * channels/chan_sip.c: Add support for accepting and sending T.38 in the initial INVITE. (closes issue #9402) Reported by: thdei 2007-12-06 12:54 +0000 [r91366] Olle Johansson * main/loader.c, include/asterisk/logger.h, main/logger.c: Make sure logger is reloaded at general reload in the cli. (Discovered during Asterisk training in Portugal) 2007-12-05 22:57 +0000 [r91273-91292] Mark Michelson * apps/app_voicemail.c: Reverting extra stuff I didn't mean to commit * apps/app_voicemail.c, apps/app_dial.c: The 'G' option for Dial() did not properly handle the case where only a label was provided. This was due to the fact that the answering channel did not have an extension set, so ast_parseable_goto would fail. This fix eliminates the call to ast_parseable_goto on the answering channel since it is a wasteful call. The answering channel and the calling channel are both directed to the same extension and context, just different priorities, so we can just copy the values from the calling channel to the answering channel and increment the answering channel's priority. (closes issue #11382, reported by jon, patch by me with correction by jon) 2007-12-05 21:38 +0000 [r91237] Tilghman Lesher * sounds/Makefile: Upgrade to the latest version of extra sounds 2007-12-05 17:31 +0000 [r90967-91192] Russell Bryant * main/threadstorage.c: Make the lock in the threadstorage debugging code untracked to avoid a deadlock on thread destruction. (closes issue #11207) Reported by: ys Patches: threadstorage.c.diff uploaded by ys (license 281) Also fixes an open bug report: (closes issue #11446) * main/utils.c: When DEBUG_THREADS is enabled, we only have the details about who is holding a lock that we are waiting on for a mutex, not rwlocks. This should fix the problem where people have reported "core show locks" crashing sometimes. * include/asterisk/lock.h: Fix some crashes in chan_iax2 that were reported as happening on Mac systems. It turns out that the problem was the Mac version of the ast_atomic_fetchadd_int() function. The Mac atomic add function returns the _new_ value, while this function is supposed to return the old value. So, the crashes happened on unreferencing objects. If the reference count was decreased to 1, ao2_ref() thought that it had been decreased to zero, and called the destructor. However, there was still an outstanding reference around. (closes issue #11176) (closes issue #11289) * include/asterisk/file.h, configure, include/asterisk/autoconfig.h.in, configure.ac, include/asterisk/compiler.h: Modify file.h to maintain API compatibility with earlier versions. If a recent compiler is being used, then a warning will show up for any modules still using the old name "private" instead of "_private". (patch suggested by paravoid) * main/pbx.c: Make some changes to some additions I made recently for doing channel autoservice when looking up extensions. This code was added to handle the case where a dialplan switch was in use that could block for a long time. However, the way that I added it, it did this for all extension lookups. However, lookups in the in-memory tree of extensions should _not_ take long enough to matter. So, move the autoservice stuff to be only around executing a switch. 2007-12-04 17:28 +0000 [r90876] Jason Parker * main/channel.c: If we fail to create a channel after allocating a timing fd, we need to make sure to close it. Issue 11454, patch by eliel. 2007-12-04 05:29 +0000 [r90798] Joshua Colp * apps/app_dial.c: Fix build issue on the build cluster. 2007-12-03 23:50 +0000 [r90736-90753] Tilghman Lesher * include/asterisk/compat.h: Solaris requires the inclusion of sys/loadavg.h for getloadavg(). Reported by: snuffy Patch by: snuffy,tilghman (Closes issue #11430) * res/res_config_pgsql.c: If both dbhost and dbsock were not set, a NULL deref could result Reported by: xrg Patch by: tilghman (Closes issue #11387) 2007-12-03 23:12 +0000 [r90735] Mark Michelson * apps/app_dial.c, main/channel.c, main/global_datastores.c (added), channels/chan_local.c, main/Makefile, include/asterisk/channel.h, include/asterisk/global_datastores.h (added), apps/app_queue.c: A big one... This is the merge of the forward-loop branch. The main change here is that call-forwards can no longer loop. This is accomplished by creating a datastore on the calling channel which has a linked list of all devices dialed. If a forward happens, then the local channel which is created inherits the datastore. If, through this progression of forwards and datastore inheritance, a device is attempted to be dialed a second time, it will simply be skipped and a warning message will be printed to the CLI. After the dialing has been completed, the datastore is detached from the channel and destroyed. This change also introduces some side effects to the code which I shall enumerate here: 1. Datastore inheritance has been backported from trunk into 1.4 2. A large chunk of code has been removed from app_dial. This chunk is the section of code which handles the call forward case after the channel has been requested but before it has been called. This was removed because call-forwarding still works fine without it, it makes the code less error-prone should it need changing, and it made this set of changes much less painful to just have the forwarding handled in one place in each module. 3. Two new files, global_datastores.h and .c have been added. These are necessary since the datastore which is attached to the channel may be created and attached in either app_dial or app_queue, so they need a common place to find the datastore info. This approach was taken in case similar datastores are needed in the future, there will be a common place to add them. 2007-12-03 22:06 +0000 [r90696] Jason Parker * apps/app_meetme.c: Make sure we always close the conference fd if we have an open one. Issue 11383, reported by markmhy, patch by eliel. 2007-12-03 20:59 +0000 [r90639] Mark Michelson * channels/chan_mgcp.c: Changing some bad logic when calculating the interdigit timeout. (closes issue #11402, reported and patched by eferro) 2007-12-03 20:51 +0000 [r90607] Jason Parker * res/res_features.c: Fix crash in ParkAndAnnounce application. Issue #11436, reported by lytledd, patch by eliel. 2007-12-03 20:05 +0000 [r90548-90588] Joshua Colp * main/rtp.c: Do not create a smoother for G723.1 frames, they need to be left alone to their native 20/24 byte size. * .cleancount, main/channel.c, include/asterisk/channel.h: Preserve the indication currently playing on a channel when a masquerade operation happens. (issue #BE-88) 2007-12-03 18:20 +0000 [r90546] Jason Parker * channels/chan_iax2.c: Only log debug messages if debug is enabled. Closes issue #11416, patch by casper. 2007-12-02 18:18 +0000 [r90470] Russell Bryant * apps/app_queue.c: The other day when I went through making changes as a result of the ao2_link() change, I added some code to set pointers to NULL after they were unreferenced. This pointed out that in this place, the object was unreferenced before the code was done using it. So, move the unref down a little bit. (crash reported by jmls on IRC) 2007-12-02 09:34 +0000 [r90432] Tilghman Lesher * main/autoservice.c: Clarify the return value on autoservice. Specifically, if you started autoservice and autoservice was already on, it would erroneously return an error. Reported by: adiemus Patch by: dimas (Closes issue #11433) 2007-11-30 19:26 +0000 [r90310-90348] Russell Bryant * main/astobj2.c, main/manager.c, include/asterisk/astobj2.h, apps/app_queue.c, channels/chan_iax2.c: Change the behavior of ao2_link(). Previously, in inherited a reference. Now, it automatically increases the reference count to reflect the reference that is now held by the container. This was done to be more consistent with ao2_unlink(), which automatically releases the reference held by the container. It also makes it so it is no longer possible for a pointer to be invalid after ao2_link() returns. * include/asterisk/astobj2.h: Add some notes on the behavior of ao2_unlink() after a discussion with Tilghman 2007-11-30 14:43 +0000 [r90269] Joshua Colp * channels/chan_sip.c: Fix locking issues under one legged replaces scenarios. (closes issue #11420) Reported by: irroot Patches: chan_sip_oneleg.patch uploaded by irroot (license 52) 2007-11-30 00:16 +0000 [r90231] Mark Michelson * channels/chan_mgcp.c: Clear the DTMF buffer if the call times out. (closes issue #11418, reported and patched by eferro) 2007-11-29 Russell Bryant * Asterisk 1.4.15 released. 2007-11-29 19:48 +0000 [r90166] Tilghman Lesher * cdr/cdr_pgsql.c: Properly escape cdr->src and cdr->dst and ensure we use thread-safe escaping (Fixes AST-2007-026) 2007-11-29 19:38 +0000 [r90163] Mark Michelson * apps/app_queue.c: This patch handles the case where a queue member with a negative penalty is added via the manager. If a negative value is submitted for a member penalty, we set it to 0. (closes issue #11411, reported and patched by Laureano) 2007-11-29 19:24 +0000 [r90154-90160] Tilghman Lesher * res/res_config_pgsql.c: Properly escape input buffers (Fixes AST-2007-025) * formats/format_g726.c, include/asterisk/file.h, formats/format_wav.c, formats/format_pcm.c, formats/format_ogg_vorbis.c, main/file.c, formats/format_h263.c, formats/format_h264.c, formats/format_wav_gsm.c: Use of "private" as a field name in a header file messes with C++ projects Reported by: chewbacca Patch by: casper (Closes issue #11401) * sounds/Makefile: Upgrade the core sounds release version 2007-11-29 00:36 +0000 [r90142-90147] Russell Bryant * funcs/func_callerid.c: fix some formatting i accidentally changed * funcs/func_callerid.c, main/channel.c, include/asterisk/channel.h: This set of changes is to make some callerID handling thread-safe. The ast_set_callerid() function needed to lock the channel. Also, the handlers for the CALLERID() dialplan function needed to lock the channel when reading or writing callerid values directly on the channel structure. * include/asterisk/file.h, main/file.c: Merge a change from team/russell/chan_refcount ... This makes ast_stopstream() thread-safe. 2007-11-28 22:59 +0000 [r90101] Joshua Colp * apps/app_queue.c: Fix a few memory leaks. (closes issue #11405) Reported by: eliel Patches: load_realtime.patch uploaded by eliel (license 64) 2007-11-28 22:30 +0000 [r90098] Kevin P. Fleming * configs/users.conf.sample, main/manager.c: it is impossible to set permissions for manager accounts created by users.conf (reported internally, patched by me) 2007-11-28 22:08 +0000 [r89999-90059] Mark Michelson * main/pbx.c: Removing some seemingly pointless code. This sets a channel variable for every priority executed in the dialplan if you have debug set to anything non-zero. This seems pointless due to the fact that these channel variables are not referenced anywhere else in the code and their names are esoteric enough that they would not be practical to reference in the dialplan. Plus the fact that this behavior isn't documented anywhere means that the change is not likely to cause any disruption. If anything, this may actually cause a slight performance increase if running with debug on. The motivating influence for this code change is the eventwhencalled option for queues. If set to vars, all channel variables will be output to the manager. These unnecessary channel variables make the output a lot more difficult to deal with. * apps/app_voicemail.c: Recording greetings when using IMAP storage was causing zero-length files to be stored. Since greetings are not retrieved from IMAP anyway, it is pointless to attempt storing them there. (closes issue #11359, reported by spditner, patched by me) 2007-11-28 00:20 +0000 [r89839-89893] Russell Bryant * main/pbx.c, include/asterisk/pbx.h: - update documentation for some of the goto functions to note that they handle locking the channel as needed - update ast_explicit_goto() to lock the channel as needed * main/autoservice.c: Don't do frame processing if ast_read() returned NULL. * apps/app_queue.c: Instead of depending on the return value of ast_true(), explicitly set the eventwhencalled variable to 1. * main/pbx.c: Don't start/stop autoservice in pbx_extension_helper() unless a channel exists 2007-11-27 23:10 +0000 [r89837] Mark Michelson * apps/app_queue.c: Two changes with regards to the 'eventwhencalled' option of queues.conf 1) Due to some signed vs. unsigned silliness, setting 'eventwhencalled' to 'vars' or 'yes' did exactly the same thing. Thus the sign change of the ast_true call. 2) The vars2manager function overwrote a \n for every channel variable it parsed, resulting in bizarre output for the channel variables. This patch remedies this. (related to issue #11385, however I'm not sure if this will actually be enough to close it) 2007-11-27 21:45 +0000 [r89790] Russell Bryant * main/autoservice.c, main/pbx.c: Merge changes from team/russell/autoservice_1.4 This set of changes fixes an issue that was reported to me on IRC yesterday. The user, d1mas, was using chan_zap for incoming calls and was having DTMF recognition issues in some situations. Specifically, he noticed that the problem occurred when using DISA or WaitExten. He also noticed that when using Read, the problem did not occur. His system also used DUNDi for dialplan lookups. So, he theorized that if the DUNDi lookups blocked for some period of time, that audio from the zap channel could get lost. If the audio got lost, then it wouldn't be run through the DTMF detector, and digits could get lost. He was correct, and the following set of changes fixes the problem. However, the changes go a little bit further than what was necessary to fix this exact problem. 1) I updated pbx_extension_helper() to autoservice the associated channel to handle cases where extension lookups may take a long time. This would normally be a dialplan switch that does some lookup over the network, such as the DUNDi or IAX2 switches. This ensures that even while a DUNDi lookup is blocking, the channel will be continuously serviced. 2) I made a change to the autoservice code. This is actually something that has bothered me for a long time. When a channel is in autoservice, _all_ frames get thrown away. However, some frames really shouldn't be thrown away. The most notable examples are signalling (CONTROL) frames, and DTMF. So, this patch queues up important frames while a channel is in autoservice. When autoservice is stopped on the channel, the queued up frames get stuck back on the channel so that they can get processed instead of thrown away. 3) I made another change to the autoservice code to handle the case where autoservice is started on channels recursively. Previously, you could call ast_autoservice_start() multiple times on a channel, and it would stop the first time ast_autoservice_stop() gets called. Now, it will ensure that autoservice doesn't actually stop until the final call to ast_autoservice_stop(). 2007-11-27 20:22 +0000 [r89727] Mark Michelson * res/res_config_pgsql.c: Changing some calls from free() to ast_free() since they were allocated with ast_calloc(). (closes issue #11390, reported and patched by Laureano) 2007-11-27 20:16 +0000 [r89701-89709] Kevin P. Fleming * main/app.c: on second thought... revert all the other changes i've made in app options parsing leaving only one: if an empty argument is supplied for an option, set that argument pointer to point to an empty string rather than NULL, so that the application can do normal checks on it without worrying about it being NULL * main/app.c: generate a warning when an application option that requires an argument is ignored due to lack of an argument 2007-11-27 16:12 +0000 [r89634] Russell Bryant * configs/voicemail.conf.sample: Add a note to the sample voicemail config noting that when using IMAP storage, only the first format specified will be attached to the message. 2007-11-27 15:38 +0000 [r89631] Tilghman Lesher * funcs/func_env.c: Default result of STAT should be "0" not "". Reported via the -users mailing list, fixed by me. 2007-11-27 15:23 +0000 [r89624-89630] Olle Johansson * main/rtp.c, channels/chan_sip.c, include/asterisk/rtp.h: If we get a codec offer using a well-known payload type, but using it for another codec that we don't know, Asterisk did not remove that codec from the list. With this patch, we remove the codec from audio and video rtp objects and deny it ever existed. Thanks to lasse for testing. (closes issue #11376) Reported by: lasse Patches: bug11376.txt uploaded by oej (license 306) Tested by: lasse * configs/sip.conf.sample: Clarify limitonpeers=yes (closes issue #11304) Reported by: pj 2007-11-27 06:24 +0000 [r89622] Steve Murphy * apps/app_dial.c, main/cdr.c, configs/cdr.conf.sample, include/asterisk/cdr.h: closes issue #11379; OK, this is an attempt to make both sides happy. To the cdr.conf file, I added the option 'unanswered', which defaults to 'no'. In this mode, you will see a cdr for a call, whether it was answered or not. The disposition will be NO ANSWER or ANSWERED, as appropriate. The src is as you'd expect, the destination channel will be one of the channels from the Dial() call, usually the last in the list if more than one chan was specified. With unanswered set to 'yes', you will still see this cdr entry in both cases. But in the case where the dial timed out, you will also see a cdr for each line attempted, marked NO ANSWER, with no destination channel name. The new option defaults to 'no', so you don't see the pesky extra cdr's by default, and you will not see the irritating 'not posted' messages. 2007-11-26 23:10 +0000 [r89616-89618] Mark Michelson * apps/app_playback.c: After issuing a "say load new", if a caller hangs up during the middle of playback of a number, app_playback will continue to try to play the remaining files. With this change, no more files will be played back upon hangup. (closes issue #11345, reported and patched by IgorG) * apps/app_playback.c: After issuing a "say load new" tons of warning messages are printed out to the CLI every time do_say in app_playback is called. Removing these warnings 2007-11-26 21:10 +0000 [r89599-89610] Joshua Colp * main/dial.c: Fix issues with async dialing with an application executing. The application has to be terminated and control returned to the thread before hanging things up. (issue #BE-252) * res/res_features.c: Add module counting removal for error conditions. (closes issue #11333) Reported by: Laureano Patches: res_features_v2.c.patch uploaded by Laureano (license 265) 2007-11-26 17:41 +0000 [r89594] Russell Bryant * main/pbx.c: Add channel locking to a function that needed to be doing it. This is just a little something I noticed while working on a completely unrelated issue. 2007-11-26 17:36 +0000 [r89587-89592] Joshua Colp * pbx/pbx_config.c: Use ast_free to free memory, or else we shall implode if MALLOC_DEBUG is enabled. (closes issue #11347) Reported by: ys Patches: pbx.pbx_config.c.diff uploaded by ys (license 281) * apps/app_mixmonitor.c: Close the audio file before sending it to the post processing application. (closes issue #11357) Reported by: reformed Patches: mixmonitor.patch uploaded by reformed (license 330) 2007-11-26 17:20 +0000 [r89586] Kevin P. Fleming * main/app.c: when parsing application options that take arguments, don't indicate that the option was supplied unless a non-zero-length argument was found for it 2007-11-26 15:48 +0000 [r89580] Mark Michelson * apps/app_voicemail.c: Revert vmu->email back to an empty string if it was empty when imap_store_file was called. This prevents sending a duplicate e-mail. (closes issue #11204, reported by spditner, patched by me) 2007-11-26 15:34 +0000 [r89571-89577] Joshua Colp * main/channel.c: If channel allocation fails because the alert pipe could not be created also free the scheduler context. (closes issue #11355) Reported by: eliel Patches: main.channel.c.patch uploaded by eliel (license 64) * apps/app_meetme.c: When unloading app_meetme destroy any auto created contexts created by SLA. (closes issue #11367) Reported by: eliel 2007-11-25 17:17 +0000 [r89559] Tilghman Lesher * res/res_odbc.c, configs/res_odbc.conf.sample, include/asterisk/res_odbc.h, res/res_config_odbc.c: We previously attempted to use the ESCAPE clause to set the escape delimiter to a backslash. Unfortunately, this does not universally work on all databases, since on databases which natively use the backslash as a delimiter, the backslash itself needs to be delimited, but on other databases that have no delimiter, backslashing the backslash causes an error. So the only solution that I can come up with is to create an option in res_odbc that explicitly specifies whether or not backslash is a native delimiter. If it is, we use it natively; if not, we use the ESCAPE clause to make it one. Reported by: elguero Patch by: tilghman (Closes issue #11364) 2007-11-24 16:59 +0000 [r89534-89545] Tilghman Lesher * res/res_adsi.c: Free some frames that would otherwise leak on error. Reported by: Laureano Patch by: Laureano,tilghman (Closes issue #11351) * apps/app_voicemail.c, main/app.c: Currently, zero-length voicemail messages cause a hangup in VoicemailMain. This change fixes the problem, with a multi-faceted approach. First, we do our best to avoid these messages from being created in the first place, and second, if that fails, we detect when the voicemail message is zero-length and avoid exiting at that point. Reported by: dtyoo Patch by: gkloepfer,tilghman (Closes issue #11083) * main/manager.c: Up until this point, the XML output of the manager has been technically invalid, due to the repetition of certain parameters in a single event. This caused various issues for XML parsers, some of which refused to parse at all, given the invalidity of the rendered XML. So this commit fixes the XML output, ensuring that each entity parameter has a unique name, thus ensuring valid XML. Reported by: msetim Patch by: tilghman (Closes issue #10220) * res/res_config_odbc.c: Use ESCAPE clause for the first parameter, not just 2nd-Nth parameters. Reported by: apsaras Patch by: tilghman (Closes issue #11353) 2007-11-22 17:29 +0000 [r89527] Russell Bryant * configs/agents.conf.sample: mvanbaak pointed out a spelling error in this sample configuration file. While I was at it, I went ahead and tweaked it a little bit more. 2007-11-21 19:27 +0000 [r89493-89495] Mark Michelson * apps/app_queue.c: Fix a small error I made in my previous commit * apps/app_queue.c: Changing an inaccurate debug message to be less inaccurate. Under the circumstances, this message would always report that there were 0 members available, even though that may not be true. 2007-11-21 18:59 +0000 [r89491] Terry Wilson * res/res_features.c: If a channel gets masqueraded in the middle of a park, don't play the announcement to the masqueraded channel, and dial back to the original channel on timeout. 2007-11-20 19:16 +0000 [r89461-89462] Kevin P. Fleming * include/asterisk/module.h: re-doxygen some comments * main/loader.c, include/asterisk/module.h, build_tools/make_buildopts_h: bring back compile-option checking when loading modules, only this time use a string-based storage and comparison mechanism because it is easier to support on other platforms 2007-11-20 17:50 +0000 [r89457] Mark Michelson * main/pbx.c: According to comments in main/pbx.c, it is essential that if we are going to lock the conlock as well as the hints lock, it must be locked in that respective order. In order to prevent a potential deadlock, we need to lock the conlock prior to locking the hints lock in ast_hint_state_changed (see the call stack example on issue #11323 for how this can happen). (closes issue #11323, reported by eelcob, suggestion for patch by eelcob, patch by me) 2007-11-20 15:22 +0000 [r89450] Steve Murphy * doc/queues-with-callback-members.txt: closes issue #11324; break statements missing in switch cases. 2007-11-20 13:40 +0000 [r89445] Christian Richter * channels/chan_misdn.c: added RR patch from iroot #10908, thanks. 2007-11-19 15:53 +0000 [r89416-89419] Joshua Colp * res/res_features.c: Print out the correct filename (features.conf) in the log message when parkpos options are incorrect. (closes issue #11295) Reported by: Laureano Patches: res_features.c.patch uploaded by Laureano (license 265) * doc/localchannel.txt: Clarify documentation a bit, include that a frame has to pass through the core in order for the Local channel optimization to happen. (closes issue #11246) Reported by: jon 2007-11-16 Russell Bryant * Asterisk 1.4.14 released. 2007-11-16 22:26 +0000 [r89339] Russell Bryant * main/loader.c, include/asterisk/module.h, build_tools/make_buildopts_h: Temporarily revert revision 89325, which added md5 magic for keeping track of what build options were used. We agreed that we should remove this before making a 1.4 release, and then we can put it back in. Then, we can take a month or so to play around with it to get it how we want it. 2007-11-16 16:47 +0000 [r89325] Kevin P. Fleming * main/loader.c, include/asterisk/module.h, build_tools/make_buildopts_h: To help combat problems where people build external modules (asterisk-addons or others) and then change the build options of the Asterisk build in a way that makes the incompatible without warning, this commit introduces an MD5 signature of the important build-time options and includes that signature into modules when they are built. When the loader loads one of these modules and notices the problem, it will emit a warning to console and refuse to initialize the module, as doing so could cause the system to be unstable or even crash. If you upgrade to this version of Asterisk, you must rebuild *all* of your modules that came from other sources before trying to run this version. If you are using Digium's G.729 binary codec module, you will need v33 or newer. 2007-11-16 15:28 +0000 [r89323] Mark Michelson * apps/app_queue.c: Make realtime queues accessible from the QUEUE_MEMBER_COUNT function. (closes issue #11271, reported and patched by atis, with small modifications from me) 2007-11-15 18:37 +0000 [r89298-89302] Tilghman Lesher * Makefile: Start Asterisk in Debian at a more reasonable time (since zaptel is at level 20) * channels/misdn/isdn_lib.c: Fix an uninitialized memory read found by valgrind * channels/chan_iax2.c: Yet another memory corruption issue. Reported by: atis Patch by: tilghman Fixes issue #10923 2007-11-15 17:19 +0000 [r89296] Russell Bryant * apps/app_meetme.c: Update the SLAStation application to account for the case where the SLA thread has a call out to the station, but the user has pressed a line button to answer the call instead of picking up the handset. If they do, the phone sends out a new INVITE. So, the SLAStation app must check to see if it is picking up a ringing trunk, and ensure that the other stations stop ringing. (reported internally, patched by me, tested by mogorman) 2007-11-15 14:57 +0000 [r89286-89288] Mark Michelson * main/manager.c: Undoing previous commit since I realize it was wrong * main/manager.c: Adding a missing mutex unlock. (closes issue 11256, reported and patched by ys) 2007-11-15 11:26 +0000 [r89280-89281] Olle Johansson * channels/chan_sip.c: Don't send re-invites during pending INVITE transactions. Patch by one47 - thanks! Closes issue #9305 * channels/chan_sip.c: Improve support for multipart messages. Code by gasparz, changes by me (mostly formatting). Thanks, gasparz! Closes issue #10947 2007-11-14 23:23 +0000 [r89275] Tilghman Lesher * main/app.c: When a recording ends with '#', we are improperly trimming an extra 200ms from the recording. Reported by: sim Patch by: tilghman Closes issue #11247 2007-11-14 01:15 +0000 [r89260] Joshua Colp * main/srv.c: Return the proper value when the srv_callback function executes properly. (closes issue #11240) Reported by: jtodd 2007-11-13 21:07 +0000 [r89248-89254] Jason Parker * channels/chan_zap.c, channels/chan_iax2.c: Fix building on newer systems which require a third arg to open() when using O_CREAT. Issue 11238, reported by puzzled. * res/res_features.c: Revert change from revision 67064. It is documented behavior that if a parking extension already exists while using PARKINGEXTEN, dialplan execution will continue. If blind transferring to a Park with PARKINGEXTEN, you must keep this in mind, and handle the failure yourself. Issue 11237, reported by jon. 2007-11-13 17:34 +0000 [r89246] Tilghman Lesher * channels/chan_sip.c: If we set a value for qualify, we should actually pay attention to it, instead of overriding the value 2007-11-13 16:02 +0000 [r89241] Mark Michelson * apps/app_mixmonitor.c: Reverting commit made in revision 89205 since it is unnecessary. Thanks to Kevin for pointing this out 2007-11-13 13:51 +0000 [r89239] Tilghman Lesher * main/utils.c: Debugging is running into the 16-lock limit. Increase to avoid. (This define is only effective when debugging is turned on, so there's no effect for most installations.) 2007-11-13 00:56 +0000 [r89205] Mark Michelson * apps/app_mixmonitor.c: Some sanity checking for MixMonitor. If only 1 argument is given, then the args.options and args.post_process strings are uninitialized and could contain garbage. This change handles this situation properly by only using arguments that we have parsed. 2007-11-12 20:46 +0000 [r89194] Jason Parker * main/pbx.c: Fix a typo pointed out by De_Mon on #asterisk-dev 2007-11-12 20:16 +0000 [r89184-89191] Tilghman Lesher * main/config.c: If two config writes collide, file corruption could result. Use a mkstemp() file, instead. Reported by: paravoid Patch by: tilghman Closes issue #10781 * main/channel.c, channels/chan_sip.c: Fix two cases of memory corruption caused by background threads. Reported by: atis Patch by: tilghman Fixes issue #10923 2007-11-12 11:26 +0000 [r89169-89173] Christian Richter * channels/chan_misdn.c, configs/misdn.conf.sample: if we're NT and no number was dialed and overlapdial is set, we wait for the ISDN timeout instead of starting our own timer. added a comment for the misdn.conf.sample for the overlapdial config option. * channels/misdn/isdn_lib.c, channels/misdn/isdn_lib_intern.h, channels/chan_misdn.c, channels/misdn/isdn_msg_parser.c: added restart all interfaces Restart_Indicator, to automatically send a RESTART after the L2 of a PTP Port comes up. Also fixed some places where we have send a RELEASE without need for it. * channels/misdn/isdn_lib.c, channels/chan_misdn.c: fixed a state/event issue with overlapdial=yes when no extension matched. removed the general sending of a RELEASE_COMPLETE when we receive a RELEASE, this is done by mISDNuser/mISDN. This makes it possible to use asterisk-1.4 with mISDN trunk, but requires users of mISDN/mISDNuser-1.1.X to upgrade to at least mISDNuser-1.1.6 (when using the NT mode at all) * channels/misdn/isdn_lib.c: fixed the support for CW and therefore for the reject_cause option. * channels/misdn/isdn_lib.c, channels/misdn_config.c, channels/misdn/isdn_lib.h, channels/chan_misdn.c, channels/misdn/chan_misdn_config.h, configs/misdn.conf.sample: aded ntkeepcalls option, to avoid droƃpping calls when the L2 goes down on a PTP link. There are some pbx which do turn off the L1 for a very short while and restart it immediately. normally T310 should be started and after 10 seconds or so the calls should be dropped, this is a simple fix wihtout this timer. 2007-11-08 23:52 +0000 [r89125] Jason Parker * main/say.c: Properly say the seconds here.. Issue 11203, fix described by vma. 2007-11-08 21:00 +0000 [r89119] Mark Michelson * channels/chan_sip.c: Rework of the commit I made yesterday to use the already built-in ast_uri_decode function as opposed to my home-rolled one. Also added comments. Thanks to oej for pointing me in the right direction 2007-11-08 18:45 +0000 [r89115] Jason Parker * configs/res_odbc.conf.sample: Avoid warnings on load when using sample configuration files. Issue 11195, patch by eliel. 2007-11-08 16:47 +0000 [r89111] Mark Michelson * apps/app_voicemail.c: I made this same adjustment in trunk to fix a bug, and it makes sense to do it in 1.4 as well. If an imapfolder is specified in voicemail.conf, don't ever explicitly connect to INBOX since it may not exist. 2007-11-08 05:26 +0000 [r89105] Kevin P. Fleming * main/srv.c: fix a glaring bug in the new SRV record handling that would cause incorrect weight sorting 2007-11-08 04:55 +0000 [r89103] Tilghman Lesher * doc/valgrind.txt: Typo 2007-11-08 02:26 +0000 [r89095-89101] Joshua Colp * channels/chan_sip.c: Do not add a sip: to the beginning of the To URI unless needed. (closes issue #10756) Reported by: goestelecom * channels/chan_sip.c: Improve the devicestate logic for multiple devices. If any are available then the extension is considered available. (closes issue #10164) Reported by: nic_bellamy Patches: sip-hinting-svn-branch-1.4.patch uploaded by nic (license 299) * channels/chan_sip.c: Add support for allowing one outgoing transaction. This means if a response comes back out of order chan_sip will still handle it. I dream of a chan_sip with real transaction support. (closes issue #10946) Reported by: flefoll (closes issue #10915) Reported by: ramonpeek (closes issue #9567) Reported by: atca_pres * channels/chan_sip.c: If callerid is configured in sip.conf use that for checking the presence of an extension in the dialplan. (closes issue #11185) Reported by: spditner 2007-11-07 23:39 +0000 [r89093] Tilghman Lesher * apps/app_queue.c: The member refcount must be incremented, to avoid using it after deallocation. A huge thanks go to lvl- for patiently providing the necessary valgrind output that was necessary to finding this problem of memory corruption. Reported by: lvl- Patch by: tilghman Closes issue #11174 2007-11-07 22:40 +0000 [r89090] Mark Michelson * channels/chan_sip.c: This patch makes it possible for SIP phones to dial extensions defined with '#' characters in extensions.conf AND maintain their escaped characters when forming URI's (closes issue #10681, reported by cahen, patched by me, code review by file) 2007-11-07 21:40 +0000 [r89088] Steve Murphy * cdr/cdr_tds.c, pbx/pbx_ael.c, res/res_jabber.c: In response to 10578, I just ran 1.4 thru valgrind; some of the config leakage I've already fixed, but it doesn't hurt to double check. I found and fixed leaks in res_jabber, cdr_tds, pbx_ael. Nothing major, tho. 2007-11-07 15:56 +0000 [r89085] Mark Michelson * main/manager.c: Fixing a segfault in the manager "core show channels concise" command. (closes issue #11183, reported by arnd and patched by ys) 2007-11-07 04:07 +0000 [r89079] Tilghman Lesher * configs/extensions.ael.sample: Suppress AEL warnings on load. Reported by: eliel Patch by: eliel Closes issue #11178 2007-11-06 20:18 +0000 [r89053] Russell Bryant * res/res_musiconhold.c: Fix init_classes() so that classes that actually do have files loaded aren't treated as empty, and immediately destroyed ... 2007-11-06 19:09 +0000 [r89046] Jason Parker * codecs/codec_zap.c: Correctly set the total number of channels from a zaptel transcoder board. SPD-49, patch by Matthew Nicholson. 2007-11-06 19:09 +0000 [r89045] Tilghman Lesher * include/asterisk/lock.h: We went to the trouble of creating a method of tracking failed trylocks, then never turned it on (oops). 2007-11-06 18:53 +0000 [r89042] Olle Johansson * main/tdd.c: Bug fixes to tdd support in zaptel. 2007-11-06 18:20 +0000 [r89037] Russell Bryant * res/res_musiconhold.c: If someone were to delete the files used by an existing MOH class, and then issue a reload, further use of that class could result in a crash due to dividing by zero. This set of changes fixes up some places to prevent this from happening. (closes issue #10948) Reported by: jcomellas Patches: res_musiconhold_division_by_zero.patch uploaded by jcomellas (license 282) Additional changes added by me. 2007-11-06 17:52 +0000 [r89036] Steve Murphy * main/config.c: closes issue #8786 - where the [catname](!) and [catname](othercat1,othercat2,...) notation gets dropped across a ConfigUpdate (or any other thing that would cause a config file to be written). While I was at it, I also cleaned up some of the destroy routines to free up comments, which was not being done. Made sure the new struct I introduced is also cleaned up properly at destruction time. My code handles multiple template inclusions. Many thanks to ssokol for his patch, which, while not literally used in the final merge, served as a foundation for the fix. 2007-11-06 17:08 +0000 [r88994-89032] Joshua Colp * channels/chan_sip.c: Make it so that if a peer is determined to be unreachable using qualify their devicestate will report back unavailable. (closes issue #11006) Reported by: pj * channels/chan_zap.c: Fix improbable but possible memory leaks in chan_zap. (closes issue #11166) Reported by: eliel Patches: chan_zap.c.patch uploaded by eliel (license 64) 2007-11-06 13:50 +0000 [r88931] Russell Bryant * include/asterisk/lock.h: Remove some checks to see if locks are initialized from the non-DEBUG_THREADS versions of the lock routines. These are incorrect for a number of reasons: - It breaks the build on mac. - If there is a problem with locks not getting initialized, then the proper fix is to find that place and fix the code so that it does get initialized. - If additional debug code is needed to help find the problem areas, then this type of things should _only_ be put in the DEBUG_THREADS wrappers. 2007-11-06 02:52 +0000 [r88862] Kevin P. Fleming * include/asterisk/srv.h: update comment to match the state of the code 2007-11-05 23:29 +0000 [r88826] Mark Michelson * main/channel.c: Reworked deadlock avoidance in __ast_read. Restored audio to callback agents. (closes issue #11071, reported by callguy, patched by me, tested by callguy and Ted Brown) 2007-11-05 22:07 +0000 [r88709-88805] Russell Bryant * main/pbx.c, include/asterisk/pbx.h: After seeing crashes related to channel variables, I went looking around at the ways that channel variables are handled. In general, they were not handled in a thread-safe way. The channel _must_ be locked when reading or writing from/to the channel variable list. What I have done to improve this situation is to make pbx_builtin_setvar_helper() and friends lock the channel when doing their thing. Asterisk API calls almost all lock the channel for you as necessary, but this family of functions did not. (closes issue #10923, reported by atis) (closes issue #11159, reported by 850t) * channels/chan_sip.c: When traversing the list of channel variables here in transmit_invite(), the asterisk channel must be locked, as this data may change at any time. (I have seen numerous reports of crashes related to the handling of channel variables. There are a couple of issues on the bug tracker related to it, but it has also been noted on IRC and mailing lists. So, I am finding and fixing some places where channel variables are handled improperly.) * channels/chan_sip.c: Fix up some indentation. * main/srv.c, include/asterisk/srv.h: Merge changes from asterisk/team/kpfleming/SRV-priority-handling Previously, the SRV record support in Asterisk was broken. There was no guarantee on what record Asterisk would choose to actually use. This set of changes improves the situation by ensuring that Asterisk will choose the highest priority record. * main/channel.c: Merge the last bit of changes from asterisk/team/russell/readq-1.4 The issue here is that the channel frame readq handling got broken when the code was converted to use the linked list macros. It caused corruption of the list head and tail pointers. So, I fixed up the usage of the linked list macros and in passing, simplified the code. I also documented what the code is doing, as it was a bit difficult to figure out at first. This bug showed itself with crashes showing messed up head/tail pointers for the readq. However, there are a couple of crashes that aren't quite as obvious, but I think may be related. So, if your bug gets closed by this commit, but you still have a problem, please reopen or create a new bug report. (closes issue #10936) (closes issue #10595) (closes issue #10368) (closes issue #11084) (closes issue #10040) (closes issue #10840) 2007-11-05 18:47 +0000 [r88671] Joshua Colp * channels/chan_sip.c: If a SIP channel is put on hold multiple times do not keep incrementing the onHold value. (closes issue #11085) Reported by: francesco_r Tested by: blitzrage (closes issue #10474) Reported by: acennami 2007-11-05 17:46 +0000 [r88624] Russell Bryant * main/channel.c: Fix up datastore handling in ast_do_masquerade(). The code is intended to move any channel datastores from the old channel to the new one. However, it did not use the linked list macros properly to accomplish the task. The existing code would only work if there was only a single datastore on the old channel. 2007-11-05 17:19 +0000 [r88585] Jason Parker * channels/chan_sip.c: Make sure we destroy the config structure on configuration failure. Issue 11163, patch by eliel. 2007-11-05 16:20 +0000 [r88539] Tilghman Lesher * res/res_odbc.c: Don't check used pooled connections for connection status, as it will cause issues for prepared queries. Reported by: Nick Gorham (via -dev list) Patch by: tilghman 2007-11-04 22:38 +0000 [r88471] Luigi Rizzo * include/asterisk/stringfields.h, main/channel.c, apps/app_meetme.c, channels/chan_sip.c, channels/chan_iax2.c: Rename ast_string_field_free_pool to ast_string_field_free_memory, and ast_string_field_free_all to ast_string_field_reset_all to avoid misuse (due to too similar names and an error in documentation). Fix two related memory leaks in app_meetme. No need to merge to trunk, different fix already applied there. Not applicable to 1.2 2007-11-02 20:49 +0000 [r88328-88366] Joshua Colp * channels/chan_sip.c: Make subscribecontext behave as advertised. It will now look for the presence of a hint in the given context (be it subscribecontext or context). (closes issue #10702) Reported by: slavon * channels/chan_sip.c: If an INFO request within a dialog is received with a content length of 0 simply send back a 200 OK. It is valid to do this and the remote side is probably using it to make sure the signalling is still alive. (closes issue #5747) Reported by: chandi Patches: infofix-81430-1.patch uploaded by IgorG (license 20) 2007-11-02 16:51 +0000 [r88283] Jason Parker * main/say.c: We need to make sure to specify a language to ast_fileexists, otherwise it may fail for anything besides en Issue 11147, fix discovered by both citats and myself (independently), with input from Corydon76 2007-11-02 13:03 +0000 [r88116-88210] Tilghman Lesher * include/asterisk/lock.h: Fix build on Solaris Reported by: snuffy Patch by: ys Closes issue #11143 * doc/valgrind.txt (added): Add some notes on using valgrind 2007-11-01 16:21 +0000 [r88078] Jason Parker * channels/chan_zap.c: Make sure we set the poll fds to NULL after free()ing it. Part of issue 11017, patch by tzafrir. 2007-11-01 13:27 +0000 [r87970-88026] Joshua Colp * apps/app_meetme.c: Fix up commit for my Zap channel with spies in Meetme fix. (thanks Tony Mountifield!) * apps/app_meetme.c: If a Zap channel contains a spy or a spy is added take it out of the conference in kernel space and make it go through Asterisk so the spy gets audio from both sides. (closes issue #10060) Reported by: mparker 2007-10-31 21:23 +0000 [r87906-87908] Jason Parker * res/res_jabber.c: Make sure we free some allocated memory before returning. Issue 11131, patch by eliel. * channels/chan_gtalk.c: Don't try to allocate memory that we're just going to re-allocate later anyways. Issue 11130, patch by eliel. 2007-10-31 18:03 +0000 [r87852] Tilghman Lesher * Makefile: Create samples for ALL of the available options in asterisk.conf 2007-10-31 17:49 +0000 [r87775-87849] Steve Murphy * pbx/pbx_config.c: closes issue #11108 -- where the 'dialplan save' cli command saves a file where the semicolon is not escaped. Fixed this; User also wanted comments to be preserved across dialplan save, but this is impossible at this point in time, because comments are not stored in the dialplan. They are 'compiled' out of extensions.conf. The only way to preserve those comments is to use the config file reader/writer that the GUI uses to allow online user edits. extensions.conf is first and foremost, a config file, and is read in by the normal config-file reading routines. Then, it is processed into a dialplan (context/exten structs). * pbx/pbx_ael.c: Included some verbage in the check_includes func, to inform the user that included contexts that have no match in the AEL, might be OK, as AEL cannot check in the extensions.conf or the in-memory contexts, as they may not be there at the time of the check. 2007-10-30 23:02 +0000 [r87739] Tilghman Lesher * include/asterisk/lock.h: Fix for uninitialized mutexes on *BSD Reported by: ys Fixed by: ys Closes issue #11116 2007-10-30 21:19 +0000 [r87686] Russell Bryant * channels/chan_iax2.c: Merge the changes from team/russell/iax2_poke_fix and iax2-poke-fix-trunk There was a race condition related to the handling of POKEing peers. Essentially, a reference to a peer is held by the scheduler when there are pending callbacks, but the reference count didn't reflect it. So, it was possible for a peer to hit a reference count of zero and have its destructor begin to be called at the same time that the scheduler thread ran a POKE related callback. If that happened, a crash would likely occur. (closes issue #11082, closes issue #11094) 2007-10-30 20:29 +0000 [r87650] Jason Parker * channels/Makefile: Only try to clean out h323/ if the h323/Makefile exists. 2007-10-30 16:13 +0000 [r87571] Joshua Colp * res/res_features.c: Add two more checks before printing out a warning message about bridging. If either channel has hungup of course the bridge will have failed. (closes issue #10009) Reported by: dimas 2007-10-30 15:45 +0000 [r87567] Jason Parker * main/editline/np/vis.c: Fix build of editline on Solaris. Issue 11113, patch by snuffy. 2007-10-30 15:10 +0000 [r87534] Joshua Colp * apps/app_followme.c: Return 1.4 to a state where it builds. Changing the arguments to a function and not changing where they are used is bad, mmmk? 2007-10-30 14:31 +0000 [r87514] BJ Weschke * apps/app_followme.c: Fix issue where the recorded name wasn't getting removed correctly. (closes issue #11115) Reported by: davevg Patches: followme-v3.diff 2007-10-29 22:13 +0000 [r87460-87465] Kevin P. Fleming * codecs/gsm: missed one directory * codecs/ilbc, formats, utils/Makefile, agi/Makefile, funcs, codecs/lpc10, main/db1-ast, main/editline, main, codecs/ilbc/Makefile, pbx, res, channels, main/db1-ast/Makefile, codecs/lpc10/Makefile, utils, codecs, agi, main/editline/Makefile.in, apps, Makefile.moddir_rules, cdr: clean up (and ignore) assembler and preprocessor intermediate files if any are created during the build * Makefile: don't put '-pipe' into ASTCFLAGS if '-save-temps' is already there (used when debugging preprocessor issues) because the compiler will whine about each compile command 2007-10-29 21:06 +0000 [r87427] Mark Michelson * apps/app_voicemail.c: Removing a completely unnecessary quota check from IMAP code. 2007-10-29 20:22 +0000 [r87373-87396] Russell Bryant * main/utils.c, include/asterisk/lock.h: Add some more details to the output of "core show locks". When a thread is waiting for a lock, this will now show the details about who currently has it locked. (inspired by issue #11100) * main/astmm.c: Remove a lock that doesn't make any sense. The regions lock needs to be held when traversing the list of allocated chunks so that they can be printed out to the CLI. (Thanks to eliel on #asterisk-dev for pointing this out!) 2007-10-29 17:20 +0000 [r87342] Joshua Colp * channels/chan_sip.c: Fix issue where if both sides of the dialog cancelled the dialog at the same time chan_sip could kepe retransmitting a response for no reason. (closes issue #9566) Reported by: atca_pres Patches: bug9566.patch uploaded by oej 2007-10-29 17:13 +0000 [r87340] Jason Parker * funcs/func_realtime.c, funcs/func_cut.c: Allow some function modules to compile under dev mode. Issue 11104, patch by andrew. 2007-10-29 14:23 +0000 [r87294] Joshua Colp * main/utils.c: Fix issue with ast_unescape_semicolon going into an endless loop. (closes issue #10550) Reported by: ramonpeek Patches: unescape-85177-1.patch uploaded by IgorG (license 20) 2007-10-28 13:46 +0000 [r87262] Tilghman Lesher * funcs/func_realtime.c, funcs/func_odbc.c, funcs/func_strings.c, funcs/func_cut.c: Add autoservice to several more functions which might delay in their responses. Also, make sure that func_odbc functions have a channel on which to set variables. Reported by russell Fixed by tilghman Closes issue #11099 2007-10-26 16:34 +0000 [r87168] Steve Murphy * pbx/ael/ael-test/ref.ael-test19, pbx/ael/ael.tab.c, pbx/ael/ael.y, pbx/ael/ael_lex.c, pbx/pbx_ael.c, include/asterisk/ael_structs.h, pbx/ael/ael.tab.h, utils/ael_main.c, pbx/ael/ael-test/ref.ael-test16, pbx/ael/ael.flex: closes issue #11086 where a user complains that references to following contexts report a problem; The problem was REALLy that he was referring to empty contexts, which were being ignored. Reporter stated that empty contexts should be OK. I checked it out against extensions.conf, and sure enough, empty contexts ARE ok. So, I removed the restriction from AEL. This, though, highlighted a problem with multiple contexts of the same name. This should be OK, also. So, I added the extend keyword to AEL, and it can preceed the 'context' keyword (mixed with 'abstract', if nec.). This will turn off the warnings in AEL if the same context name is used 2 or more times. Also, I now call ast_context_find_or_create for contexts now, instead of just ast_context_create; I did this because pbx_config does this. The 'extend' keyword thus becomes a statement of intent. AEL can now duplicate the behavior of pbx_config, 2007-10-26 13:54 +0000 [r87120] Tilghman Lesher * funcs/func_curl.c: The addition of autoservice to func_curl additionally made func_curl dependent on the existence of a channel, with no real reason. This should make func_curl once again work without a channel. Reported by jmls. Fixed by tilghman. Closes issue #11090 2007-10-25 23:03 +0000 [r87069] Kevin P. Fleming * main/channel.c, include/asterisk/linkedlists.h: appending one list to another should leave the first list empty, and not require the user to do that 2007-10-25 22:53 +0000 [r87067] Tilghman Lesher * funcs/func_cut.c: Backport alternate encoding of newline delimiters from trunk to 1.4, as approved by Russell Reported by blitzrage Closes issue #10903 2007-10-24 20:56 +0000 [r86982] Jason Parker * channels/chan_zap.c: Correctly respect hidecalleridname configuration option. Simplify code slightly in the process. Issue 11079, reported by ddv2005 2007-10-24 04:14 +0000 [r86880-86936] Steve Murphy * pbx/ael/ael.tab.c, pbx/ael/ael.y: closes issue #11037 -- unable to specify app:spec in hint arguments * funcs/func_logic.c: closes issue #11052 -- where nothing after the ? will allow un-initialized variable values to corrupt and crash asterisk on 64-bit platforms * main/Makefile: this update to Makefile corrects how ast_expr2f.c should be generated * main/ast_expr2f.c: This should get rid of a really, really irritating warning generated by some 64-bit platforms from libc, where free(0) is frowned upon 2007-10-22 21:36 +0000 [r86836] Russell Bryant * include/asterisk/lock.h: If lock tracking is not enabled, then we can not attempt to log any mutex failures. If so, we could end up in infinite recursion. The only lock that is affected by this is a mutex in astmm.c used when MALLOC_DEBUG is enabled. (closes issue #11044) Reported by: ys Patches: lock.h.diff uploaded by ys (license 281) 2007-10-22 17:38 +0000 [r86787] Tilghman Lesher * main/astmm.c: Minor FreeBSD build fix 2007-10-22 16:35 +0000 [r86754-86756] Joshua Colp * channels/chan_sip.c: After reading online I have confirmed that Record-Route headers should be copied to 1xx responses as well. (closes issue #10113) Reported by: makoto * apps/app_controlplayback.c: Make sure res is a positive value before performing the check to determine whether the user stopped it or not. (closes issue #11023) Reported by: cfc 2007-10-22 15:52 +0000 [r86726-86750] Russell Bryant * main/channel.c: Don't leak a frame in the case that an END frame is received and the time since the BEGIN is less than that of the defined minimum DTMF duration. (closes issue #11051) Reported by: casper Patches: channel.c.86664.diff uploaded by casper (license 55) * include/asterisk/lock.h: Update the static mutex initializer to include the initialization of the internal mutex used to protect the lock debugging data. (closes issue #11044, patch suggested by Ivan) 2007-10-22 14:48 +0000 [r86694] Mark Michelson * apps/app_voicemail.c: Account for the fact that sometimes headers may be terminated with \r\n instead of just \n (closes issue #11043, reported by yehavi) 2007-10-22 14:27 +0000 [r86630-86663] Joshua Colp * main/channel.c: Move log message to before the frame it references is freed. (closes issue #11050) Reported by: slavon Patches: channel.c.86662.diff uploaded by casper (license 55) * pbx/pbx_dundi.c: Fix tab completion for dundi show peer. (closes issue #11041) Reported by: jsmith Patches: asterisk-dundicomplete.diff.txt uploaded by jamesgolovich (license 176) * main/loader.c: Fixes for building under OpenSolaris. (closes issue #11047) Reported by: snuffy Patches: 11047-fixes.diff uploaded by snuffy (license 35) 2007-10-22 09:21 +0000 [r86598] Christian Richter * channels/misdn/isdn_lib.c, channels/chan_misdn.c: we send DISCONNECT instead of RELEASE/RELEASE_COMPLETE if the dialplan does not match after an overlap call. Also added out_cause=1 2007-10-19 16:38 +0000 [r86469-86502] Joshua Colp * main/app.c: When returning a DTMF digit from ast_control_streamfile cast it as a char so that 0 does not overlap with the success return code. (closes issue #11023) Reported by: cfc * channels/chan_sip.c: Fix two issues with domains and transfers. If a port was given in the hostname it was treated as part of the hostname. If domains were configured but external domains were not enabled all transfers would be considered remote. (closes issue #11027) Reported by: ramonpeek Patches: 11027-1.diff uploaded by ramonpeek (license 266) * channels/chan_sip.c: Set port number in received as information for registrations as well. (closes issue #11028) Reported by: brad-x 2007-10-19 01:45 +0000 [r86438] TransNexus OSP Development * apps/app_osplookup.c: Fixed OSP module did not report source/devinfo IP in correct format. 2007-10-18 22:01 +0000 [r86405-86406] Jason Parker * Makefile: Correct documentation. I removed the wrong line.. * Makefile: Add documentation for options in asterisk.conf Issue 11029, patch by eserra 2007-10-18 21:16 +0000 [r86330-86372] Russell Bryant * configs/iax.conf.sample, channels/chan_iax2.c: Revert erroneous commit. * configs/iax.conf.sample, channels/chan_iax2.c: Add support for setting the maximum trunk size for IAX2 trunking * main/channel.c, include/asterisk/channel.h: The channel needs to stay locked while running timer callbacks, as they access and modify channel data that may change elsewhere. I went through every timer callback in the source tree to make sure that none of them did any additional locking that could introduce deadlocks, and all is well. (closes issue #10765) Reported by: Ivan Patches: ast_1_4_11_svn_patch_channel_rc.diff uploaded by Ivan (license 229) 2007-10-18 17:38 +0000 [r86328] Mark Michelson * apps/app_queue.c: If a non-existent file is specified to be played either as a periodic announcement or as a hold/position announcement, the caller would be kicked out of the queue. No longer does this happen. 2007-10-18 15:45 +0000 [r86237-86296] Russell Bryant * codecs/codec_zap.c: Execute the RELEASE operation on transcoder channels in the destroy callback. (patch from jsloan) * main/utils.c: Revert a change that I made for issue #10979 which, as has been pointed out to me in issue #11018, doesn't really make sense. There is no reason to have the base64 decode function force a '\0' terminated buffer, when the result is almost always binary, anyway. In fact, this caused some breakage, as some code in res_crypto passed in a buffer exactly the right size to get its binary result, which got stomped on by this patch. (closes issue #11018, reported by dimas) 2007-10-17 21:39 +0000 [r86202] Mark Michelson * apps/app_queue.c: Changing the strategy field of the call_queue struct to be signed instead of unsigned, since the code attempts to set the strategy to -1 if you specify a bogus strategy. While this isn't a huge issue in 1.4, it could be a problem for someone who, say, tries to use the roundrobin strategy in trunk (despite all the deprecation warnings in 1.4). 2007-10-17 17:57 +0000 [r86149] Russell Bryant * channels/chan_sip.c: If Asterisk is in the middle of shutting down, respond to OPTIONS with 503 Unavailable. (closes issue #10994) Reported by: eserra Patches: sip-options-503.patch uploaded by eserra (license 45) 2007-10-17 16:58 +0000 [r86117] Joshua Colp * channels/chan_sip.c: Whoops, forgot to remove the original sip_scheddestroy. (closes issue #11010) Reported by: vadim 2007-10-17 15:23 +0000 [r86066] Tilghman Lesher * main/asterisk.c: When runuser/rungroup is specified, a remote console could only be attained by root (Closes issue #9999) 2007-10-17 15:06 +0000 [r86063] Joshua Colp * channels/chan_sip.c: Don't schedule dialog destruction if a MESSAGE is received using an existing dialog. (closes issue #11010) Reported by: vadim 2007-10-16 23:35 +0000 [r86028-86032] Mark Michelson * configs/queues.conf.sample: Since monitor-join is deprecated now, remove the example from the sample queues.conf file * UPGRADE.txt: Updating UPGRADE.txt to reflect the deprecation of the monitor-join queue option * apps/app_queue.c: Adding deprecated warning to monitor-join option, since the plan is to no longer support this in favor of monitor-type = mixmonitor (related to issue #10885) 2007-10-16 22:36 +0000 [r85994-85997] Russell Bryant * include/asterisk/lock.h: really picky formatting tweak ... * include/asterisk/lock.h: Some locking errors exposed the fact that the lock debugging code itself was not thread safe. How ironic! Anyway, these changes ensure that the code that is accessing the lock debugging data is thread-safe. Many thanks to Ivan for finding and fixing the core issue here, and also thanks to those that tested the patch and provided test results. (closes issue #10571) (closes issue #10886) (closes issue #10875) (might close some others, as well ...) Patches: (from issue #10571) ivan_ast_1_4_12_rel_patch_lock.h.diff uploaded by Ivan (license 229) - a few small changes by me 2007-10-16 21:14 +0000 [r85958] Mark Michelson * apps/app_queue.c: Trying to remove a non-dynamic queue member via dynamic means can lead to some interesting (read nasty) situations. This pat