Commit Graph

12590 Commits

Author SHA1 Message Date
Jeff Peeler
27855de29f (closes issue #11594)
Reported by: yem
Tested by: yem

This change decreases the buffer size allocated on the stack substantially in config_text_file_load when LOW_MEMORY is turned on. This change combined with the fix from revision 117462 (making mkintf not copy the zt_chan_conf structure) was enough to prevent the crash.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@120173 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-03 22:15:33 +00:00
Russell Bryant
a5f4960b3c Fix another place where peer->callno could change at a very bad time, and also
fix a place where a peer was used after the reference was released.
(inspired by rev 120001)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@120168 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-03 21:34:55 +00:00
Tilghman Lesher
98b11ad0ee When listing the manager users, managers in users.conf are not shown, even
though they are allowed to connect.
(closes issue #12594)
 Reported by: bkruse
 Patches: 
       12594-managerusers-2.diff uploaded by qwell (license 4)
 Tested by: bkruse


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@120061 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-03 18:23:32 +00:00
Tilghman Lesher
088ac37bfc Save the callno when we're poking, because our peer structure could change
during destruction (and thus we unlock the wrong callno, causing a
cascade failure).
(closes issue #12717)
 Reported by: gewfie
 Patches: 
       20080525__bug12717.diff.txt uploaded by Corydon76 (license 14)
 Tested by: gewfie


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@120001 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-03 16:10:53 +00:00
Steve Murphy
6f93af198e Updated the regressions on AEL. Hadn't updated
this for the changes I made to preserve ${EXTEN}
in switches, which affected several tests because
it adds extra priorities, and at least one needed to be updated
because of the removal of the empty extension warning
message.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119966 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-03 15:26:56 +00:00
Steve Murphy
bfd56d7f25 as per http://lists.digium.com/pipermail/asterisk-users/2008-June/212934.html,
which is a message from Philipp Kempgen, requesting that the WARNING
that an extension is empty be reduced to a NOTICE or less, as empty
extensions are syntactically possible, and no big deal.

With which I agree, and have removed that WARNING message entirely.
I think it is not necessary to see this message. It didn't 
state that a NoOp() was inserted automatically on your behalf,
and really, as users, who cares? Why freak out dialplan writers
with unnecessary warnings? The details of the machinations a compiler goes
thru to produce working assembly code is of little interest
to most programmers-- we will follow the unix principal of
doing our work silently.




git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119929 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-03 14:49:46 +00:00
Joshua Colp
6d78e78947 Treat ECONNREFUSED as an error that will stop further retransmissions. (issue #AST-58, patch from Switchvox)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119926 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-03 14:46:24 +00:00
Russell Bryant
f4cd9e3958 Revert a change made for issue #12479. This change caused a regression such that
a dial string such as (IAX2/foo) did not automatically fall back to dialing the 's'
extension anymore.

(closes issue #12770)
Reported by: dagmoller


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119838 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 20:08:04 +00:00
Russell Bryant
8a9d52bc7f Improve CLI command blacklist checking for the command manager action. Previously,
it did not handle case or whitespace properly.  This made it possible for blacklisted
commands to get executed anyway.
(closes issue #12765)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119742 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 14:39:45 +00:00
Philippe Sultan
59410a3f01 Do not link the guest account with any configured XMPP client (in
jabber.conf). The actual connection is made when a call comes in
Asterisk.

Fix the ast_aji_get_client function that was not able to retrieve an
XMPP client from its JID.

(closes issue #12085)
Reported by: junky
Tested by: phsultan

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119740 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 14:32:53 +00:00
Russell Bryant
35ea2643d4 Even of the first PING or LAGRQ doesn't get sent because it comes up too soon,
make sure to reschedule so it gets sent later.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119687 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 12:30:17 +00:00
Christian Richter
b145e2f8da fixed compile issue when dev-mode is enabled
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119636 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 09:29:21 +00:00
Christian Richter
a3fe7673a9 Added counter for unhandled_bmsg Print, this prevents the logs to be flooded to fast and save CPU in this error scenario. Added 'last_used' element to bc structure, when a bchannel changes from used to free this exact time will be marked in last_used. When a new channel is requested the find_free_chan function will check if the new empty channel was used within the last second, if yes it will search for the next channel, if no it will return this channel. This simple mechanism has prooven to prevent race conditions where the NT and TE tried to allocate the exact same channel at the same time (RELEASE cause: 44).
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119585 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 08:35:28 +00:00
Russell Bryant
69213c8eb6 Change a debug message to an actual debug message
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119533 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 01:06:09 +00:00
Russell Bryant
c6c26f7c34 Fix another typo in documentation
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119530 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-02 01:03:22 +00:00
Michiel van Baak
383a1ece6b small typo fix 'retires' => 'retries'
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119478 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-06-01 20:47:55 +00:00
Tilghman Lesher
c9ddda2b1f When joinempty=strict, it only failed on join if there were busy members. If
all members were logged out OR paused, then it (incorrectly) let callers join
the queue.
(closes issue #12451)
 Reported by: davidw


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119404 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-30 21:17:45 +00:00
Joshua Colp
9f123152fa Fix a bug I found while testing for another issue.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119354 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-30 19:46:37 +00:00
Michiel van Baak
1540ba27c1 dont use a bashism way to check the $VERSION variable.
The rc/init.d scripts, and safe_asterisk work on normal sh now again.
Tested on:
OpenBSD 4.2 (me)
Debian etch (me)
Ubuntu Hardy (me and loloski)
FC9 (loloski)

(closes issue #12687)
Reported by: loloski
Patches:
      20080529-12687-safe_asterisk-fixversion.diff.txt uploaded by mvanbaak (license 7)
	  Tested by: loloski, mvanbaak


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119301 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-30 16:44:39 +00:00
Russell Bryant
31d518c8e6 Merged revisions 119237 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r119237 | russell | 2008-05-30 07:49:39 -0500 (Fri, 30 May 2008) | 7 lines

- Instead of only enforcing destination call number checking on an ACK, check
  all full frames except for PING and LAGRQ, which may be sent by older versions
  too quickly to contain the destination call number.
  (As suggested by Tim Panton on the asterisk-dev list)
- Merge changes from team/russell/iax2-frame-race, which prevents PING and LAGRQ
  from being sent before the destination call number is known.

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119238 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-30 12:55:36 +00:00
Russell Bryant
9a01bdae26 Fix a race condition in channel autoservice. There was still a small window of opportunity
for a DTMF frame, or some other deferred frame type, to come in and get dropped.

(closes issue #12656)
(closes issue #12656)
Reported by: dimas
Patches:
      v3-12656.patch uploaded by dimas (license 88)
	  -- with some modifications by me


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119156 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 22:24:29 +00:00
Russell Bryant
3d461c7cb6 Oddly enough, all of the contents of audiohook.h were in there twice. I have
removed the second copy.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119076 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 20:48:33 +00:00
Tilghman Lesher
b2f0add41c Call waiting tone occurs too often, because it's getting serviced by both
subchannels.
(closes issue #11354)
 Reported by: cahen
 Patches: 
       20080512__bug11354.diff.txt uploaded by Corydon76 (license 14)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119071 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 20:24:11 +00:00
Russell Bryant
e4f25aab4b - Fix a typo in the argument to Playtones
- use ast_safe_sleep() instead of calling the wait application
(thanks to tilghman for pointing these out!)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119012 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 19:04:52 +00:00
Russell Bryant
e0c741c5e3 Merged revisions 119008 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r119008 | russell | 2008-05-29 13:45:21 -0500 (Thu, 29 May 2008) | 7 lines

Merge changes from team/russell/iax2-another-fix-to-the-fix

As described in the following post to the asterisk-dev mailing list, only
enforce destination call numbers when processing an ACK.

http://lists.digium.com/pipermail/asterisk-dev/2008-May/033217.html

(closes issue #12631)
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@119009 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 18:49:12 +00:00
Russell Bryant
ecc4690b4b - Mark app_milliwatt dependent on res_indications (thanks to jsmith)
- fix a typo in a log message (thanks to qwell)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118961 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 17:51:29 +00:00
Russell Bryant
e5b9da59e2 Change milliwatt to use the proper tone by default (1004 Hz) instead of 1000 Hz.
An option is there to use 1000 Hz for anyone that might want it.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118956 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 17:38:38 +00:00
Tilghman Lesher
ba9f012573 Define also when not DEBUG_THREADS
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118954 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 17:33:01 +00:00
Tilghman Lesher
65808210e9 Add some debugging code that ensures that when we do deadlock avoidance, we
don't lose the information about how a lock was originally acquired.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118953 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 17:20:16 +00:00
Steve Murphy
e58b5c63c6 (closes issue #10668)
(closes issue #11721)
(closes issue #12726)
Reported by: arkadia
Tested by: murf

These changes:

1. revert the changes made via bug 10668; 
   I should have known that such changes,
   even tho they made sense at the time,
   seemed like an omission, etc, were actually
   integral to the CDR system via forkCDR.
   It makes sense to me now that forkCDR didn't
   natively end any CDR's, but rather depended
   on natively closing them all at hangup time
   via traversing and closing them all, whether
   locked or not. I still don't completely 
   understand the benefits of setvar and answer
   operating on locked cdrs, but I've seen 
   enough to revert those changes also, and
   stop messing up users who depended on that
   behavior. bug 12726 found reverting the changes
   fixed his changes, and after a long review
   and working on forkCDR, I can see why.
2. Apply the suggested enhancements proposed
   in 10668, but in a completely compatible
   way. ForkCDR will behave exactly as before,
   but now has new options that will allow some
   actions to be taken that will slightly 
   modify the outcome and side-effects of
   forkCDR. Based on conversations I've had 
   with various people, these small tweaks
   will allow some users to get the behavior
   they need. For instance, users executing
   forkCDR in an AGI script will find the
   answer time set, and DISPOSITION set, 
   a situation not covered when the routines
  were first written.
3. A small problem in the cdr serializer
   would output answer and end times even
   when they were not set. This is now 
   fixed.




git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118858 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-29 00:25:28 +00:00
Brett Bryant
3ab48f9299 merge revision 118702 from trunk to 1.4 -- Fixes a bug in chan_iax that uses send_command to poke a peer while a channel is unlocked in some cases, and because it can cause seemingly random failures could be related to some bugs in the tracker...
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118716 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-28 16:10:48 +00:00
Joshua Colp
405dfcb54a Add an option to use the source IP address of RTP as the destination IP address of UDPTL when a specific option is enabled. If the remote side is properly configured (ports forwarded) then UDPTL will flow.
(closes issue #10417)
Reported by: cstadlmann


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118646 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-28 14:23:34 +00:00
Joshua Colp
a403fd8ea1 Fix an issue where codec preferences were not set on dialogs that were not authenticated via a user or peer and allow framing to work without rtpmap in the SDP.
(closes issue #12501)
Reported by: slimey


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118558 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-27 19:32:38 +00:00
Tilghman Lesher
1a73396c9d When showing an error message for a command, don't shorten the command output,
as it tends to confuse the user (it's fine for suggesting other commands,
however).
 Reported by: seanbright (on #asterisk-dev)
 Fixed by: me


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118551 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-27 19:15:27 +00:00
Mark Michelson
a7f2c5dbf9 Russell noted to me that in the case that separate threads use their
own addressing system, the fix I made for issue 12376 does not guarantee
uniqueness to the datastores' uids. Though I know of no system that works
this way, I am going to change this right now to prevent trying to track
down some future bug that may occur and cause untold hours of debugging
time to track down.

The change involves using a global counter which increases with each new
chanspy_ds which is created. This guarantees uniqueness.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118509 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-27 19:07:26 +00:00
Tilghman Lesher
7ca3880d4e NULL character should terminate only commands back to the core, not log
messages to the console.
(closes issue #12731)
 Reported by: seanbright
 Patches: 
       20080527__bug12731.diff.txt uploaded by Corydon76 (license 14)
 Tested by: seanbright


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118465 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-27 18:58:09 +00:00
Michiel van Baak
68589940b4 small update to the g() option of app_voicemail to
note that gain changes only work on zap channels right now.

issue #12578 shows it's not clear right now.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118416 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-27 17:17:20 +00:00
Mark Michelson
9460de70ef Add a unique id to the datastore allocated in app_chanspy since
it is possible that multiple spies may be listening to the same
channel.

(closes issue #12376)
Reported by: DougUDI
Patches:
      12376_chanspy_uid.diff uploaded by putnopvut (license 60)
Tested by: destiny6628

(closes issue #12243)
Reported by: atis



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118365 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-27 16:38:38 +00:00
Tilghman Lesher
0ed598406b Add a note that pbx_config.so is needed for Local channels.
(Closes issue #12671)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118358 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-27 15:45:37 +00:00
Tilghman Lesher
0dab692af5 Realtime flag affects construction in multiple ways, so consulting whether
rtcachefriends was set was done too soon (needed to be done inside build_peer,
not just as a flag to build_peer).
Also, fullcontact needed to be reconstructed, because realtime separates the
embedded ';' into multiple fields.
(closes issue #12722)
 Reported by: barthpbx
 Patches: 
       20080525__bug12722.diff.txt uploaded by Corydon76 (license 14)
 Tested by: barthpbx
 (Much of the discussion happened on #asterisk-dev for diagnosing this issue)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118251 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-25 16:02:04 +00:00
Jeff Peeler
ac177d4459 Fix a few things I missed to ensure zt_chan_conf structure is not modified in mkintf
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118163 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-23 21:21:35 +00:00
Tilghman Lesher
3fcdfbf20f Add format type checking for recently de-inlined function
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118055 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-23 13:18:44 +00:00
Tilghman Lesher
c8e3c498d0 Add information on using the Asterisk console, including tab command line
completion.  (Closes issue #12681)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118052 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-23 12:59:16 +00:00
Russell Bryant
a3d59980ea Don't declare a function that takes variable arguments as inline, because it's
not valid, and on some compilers, will emit a warning.

http://gcc.gnu.org/onlinedocs/gcc/Inline.html#Inline

(closes issue #12289)
Reported by: francesco_r
Patches by Tilghman, final patch by me


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118048 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-23 12:30:53 +00:00
Tilghman Lesher
2454daba41 Also remove preamble from asynchronous events (reported by jsmith on #asterisk-dev)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@117899 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-22 18:53:53 +00:00
Tilghman Lesher
2691e0d5b0 Take into account the length of delimiters when calculating result string length.
(closes issue #12696)
 Reported by: adomjan
 Patches: 
       func_realtime.c-longdelimiter.patch uploaded by adomjan (license 487)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@117809 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-22 16:47:03 +00:00
Jeff Peeler
b77e30e6f5 Ensure that passed in zt_chan_conf structure is not modified in mkintf.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@117582 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-21 20:11:14 +00:00
Joshua Colp
6627976f63 Apply the autoframing setting to dialogs that do not get matched against a user or peer.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@117574 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-21 19:38:28 +00:00
Tilghman Lesher
7cf2eecaf6 Revert accidental commit of the last change
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@117523 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-21 18:44:53 +00:00
Tilghman Lesher
0b0f6a1a58 Strip the preamble from the output also when -rx is not being used
(Related to issue #12702)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@117519 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-05-21 18:40:14 +00:00