Commit Graph

12832 Commits

Author SHA1 Message Date
Kevin P. Fleming
3afd38a555 add document describing what users will need to be aware of when upgrading to this version and using DAHDI
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@137530 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-13 20:46:19 +00:00
Kevin P. Fleming
2ebf0eee36 remove some more chan_zap references
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@137529 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-13 20:42:33 +00:00
Kevin P. Fleming
d98254b147 document dahdichanname option in doc/asterisk-conf.txt
make chan_dahdi read its configuration from zapata.conf if dahdichanname has been set to 'no'



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@137527 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-13 20:33:47 +00:00
Sean Bright
1b6d4f92e9 Update docs to reflect the change to cdr_tds
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@137405 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-13 14:33:49 +00:00
Sean Bright
284d93f5d9 Bring cdr_tds in line with the other CDR backends and have it try to store
CDR(userfield) if it is set.  The new behavior is to check for the userfield
column on module load, and if it exists, we will store CDR(userfield) when
CDRs are written.  A similar patch already went into trunk and 1.6.0.

(closes issue #13290)
Reported by: falves11


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@137348 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-13 00:10:35 +00:00
Kevin P. Fleming
a57dd05769 convert this module to be able to handle DAHDI or Zaptel (reported on asterisk-users, don't know how this got missed before)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@137188 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-11 13:33:35 +00:00
Tilghman Lesher
9d294cd934 Deallocate database connection handle on disconnect, as we allocate another
one on connect.
(closes issue #13271)
 Reported by: dveiga


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@137138 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-11 00:20:38 +00:00
Russell Bryant
2f11017cc1 Ensure PBX_DAHDI_TRANSCODE will evaluate to 0 if not found instead of empty.
pointed out by tzafrir on #asterisk-dev


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136999 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-09 17:11:27 +00:00
Tilghman Lesher
6d7a2a5fa4 Merged revisions 136945 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r136945 | tilghman | 2008-08-09 10:24:36 -0500 (Sat, 09 Aug 2008) | 2 lines

Regression fixes for Solaris

........


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136946 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-09 15:25:36 +00:00
Steve Murphy
195fe34304 (closes issue #13236)
Reported by: korihor

Wow, this one was a challenge!

I regrouped and ran a new strategy for
setting the ~~MACRO~~ value; I set it once
per extension, up near the top. It is only
set if there is a switch in the extension.

So, I had to put in a chunk of code to detect
a switch in the pval tree.

I moved the code to insert the set of ~~exten~~
up to the beginning of the gen_prios routine, 
instead of down in the switch code.

I learned that I have to push the detection
of the switches down into the code, so everywhere
I create a new exten in gen_prios, I make sure
to pass onto it the values of the mother_exten
first, and the exten next.

I had to add a couple fields to the exten
struct to accomplish this, in the ael_structs.h
file. The checked field makes it so we don't
repeat the switch search if it's been done.

I also updated the regressions.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136726 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-08 00:15:34 +00:00
Kevin P. Fleming
31446d74a7 change the required dependency for codec_dahdi to only be satisfied by DAHDI and not Zaptel, as the new transcoder interface is only in DAHDI
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136560 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 18:25:31 +00:00
Shaun Ruffell
b6501cdb43 Updated codec_dahdi to use the new transcoder interface in the first DAHDI
release.  Codec dahdi no longer functions with the transcoder interface in
zaptel at this time (which the last zaptel release was 1.4.11).

NOTE: Still needs an update to the configure script to make sure that
codec_dahdi is only built if the new transcoder interface is present in the
drivers.

(Issue: DAHDI-42)



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136544 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 18:14:17 +00:00
Tilghman Lesher
925996df48 Update persistent state on all exit conditions.
(closes issue #12916)
 Reported by: sgenyuk
 Patches: 
       app_queue.patch.txt uploaded by neutrino88 (license 297)
 Tested by: sgenyuk, aragon


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136488 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 16:50:47 +00:00
Kevin P. Fleming
c269b9ba10 add a raw list of all libraries that any part of Asterisk links directly to
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136484 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 16:30:55 +00:00
Kevin P. Fleming
24dedd7016 work around a bug in gcc-4.2.3 that incorrectly ignores the casting away of 'const' for pointers when the developer knows it is safe to do so
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136458 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 16:11:17 +00:00
Kevin P. Fleming
b9b6f29610 remove config.cache during distclean, in case the user is using autoconf caching
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136404 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 15:07:12 +00:00
Tilghman Lesher
f2ead6dbc5 Also, parse useincomingcalleridonzaptransfer (and add appropriate deprecation
warnings).


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136348 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 01:31:27 +00:00
Tilghman Lesher
d0721c085f For backwards compatibility with previous 1.4 versions which used "zapchan"
in users.conf, ensure that we still support it.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136304 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-07 01:17:14 +00:00
Richard Mudgett
57e3570b62 * The allowed_bearers setting in misdn.conf misspelled one
of its options: digital_restricted.
*  Fixed some other spelling errors and typos.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136241 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 21:18:53 +00:00
Mark Michelson
7dcb58af43 We only need to unregister the QueueStatus manager
command once on an unload



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136238 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 20:42:15 +00:00
Tilghman Lesher
43bd872365 -C option takes a filename, not a directory path.
(closes issue #13007)
 Reported by: klaus3000


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136190 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 20:14:54 +00:00
Russell Bryant
2ec4a1b050 Remove the use of --no-print-directory when compiling subdirectories.
This allows vim :make functionality to work properly when errors have
occurred in the build.  Without printing the directories, vim did not
know how to find the file that the error occurred in.

If the extra bit of build noise annoys anyone, just let me know, and
I'll make this optional.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136168 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 18:58:37 +00:00
Mark Michelson
b48adf96dc Since adding the AST_CONTROL_SRCUPDATE frame type,
there are places where ast_rtp_new_source may be called
where the tech_pvt of a channel may not yet have an
rtp structure allocated. This caused a crash in chan_skinny,
which was fixed earlier, but now the same crash has been 
reported against chan_h323 as well. It seems that the best 
solution is to modify ast_rtp_new_source to not attempt to 
set the marker bit if the rtp structure passed in is NULL.

This change to ast_rtp_new_source also allows the removal
of what is now a redundant pointer check from chan_skinny.

(closes issue #13247)
Reported by: pj



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@136062 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 15:58:40 +00:00
Tilghman Lesher
b8550b63bc Fix a longstanding bug in channel walking logic, and fix the explanation to
make sense.
(Closes issue #13124)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135949 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 03:53:36 +00:00
Tilghman Lesher
cd17593356 Since powerof() can return an error condition, it's foolhardy not to detect and
deal with that condition.
(Related to issue #13240)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135915 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 03:24:56 +00:00
Tilghman Lesher
1a0c9841dd 1) Bugfix for debugging code
2) Reduce compiler warnings for another section of debugging code
(Closes issue #13237)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135899 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 03:02:59 +00:00
Mark Michelson
91222d7c12 Remove properties that should not be here
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135850 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 00:29:54 +00:00
Mark Michelson
bae517b1e2 Revert inadvertent changes to app_skel that occurred when
I was testing for a memory leak



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135847 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 00:27:54 +00:00
Mark Michelson
b8bbf8b61a Merging the issue11259 branch.
The purpose of this branch was to take into account
"burps" which could cause jitterbuffers to misbehave.
One such example is if the L option to Dial() were used
to inject audio into a bridged conversation at regular
intervals. Since the audio here was not passed through
the jitterbuffer, it would cause a gap in the jitterbuffer's
timestamps which would cause a frames to be dropped for a 
brief period.

Now ast_generic_bridge will empty and reset the jitterbuffer
each time it is called. This causes injected audio to be handled
properly.

ast_generic_bridge also will empty and reset the jitterbuffer
if it receives an AST_CONTROL_SRCUPDATE frame since the change
in audio source could negatively affect the jitterbuffer.

All of this was made possible by adding a new public API call
to the abstract_jb called ast_jb_empty_and_reset.

(closes issue #11259)
Reported by: plack
Tested by: putnopvut



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135841 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-06 00:25:10 +00:00
Steve Murphy
ee8adb313e (closes issue #12982)
Reported by: bcnit
Tested by: murf

I discovered that also, in the previous bug fixes and changes,
the cdr.conf 'unanswered' option is not being obeyed, so
I fixed this.

And, yes, there are two 'answer' times involved in this
scenario, and I would agree with you, that the first 
answer time is the time that should appear in the CDR.
(the second 'answer' time is the time that the bridge
was begun).

I made the necessary adjustments, recording the first
answer time into the peer cdr, and then using that to
override the bridge cdr's value.

To get the 'unanswered' CDRs to appear, I purposely
output them, using the dial cmd to mark them as
DIALED (with a new flag), and outputting them if
they bear that flag, and you are in the right mode.

I also corrected one small mention of the Zap device
to equally consider the dahdi device.

I heavily tested 10-sec-wait macros in dial, and
without the macro call; I tested hangups while the
macro was running vs. letting the macro complete
and the bridge form. Looks OK. Removed all the
instrumentation and debug.




git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135799 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-05 23:13:20 +00:00
Tilghman Lesher
42a5577557 In a conversion to use ast_strlen_zero, the meaning of the flag IAX_HASCALLERID
was perverted.  This change reverts IAX2 to the original meaning, which was,
that the callerid set on the client should be overridden on the server, even if
that means the resulting callerid is blank.  In other words, if you set
"callerid=" in the IAX config, then the callerid should be overridden to blank,
even if set on the client.  Note that there's a distinction, even on realtime,
between the field not existing (NULL in databases) and the field existing, but
set to blank (override callerid to blank).


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135747 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-05 21:34:46 +00:00
Sean Bright
0fa63ffb6f Use PATH_MAX for filenames
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135597 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-05 13:25:00 +00:00
Russell Bryant
c981603ce4 fix a config sample typo
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135536 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-04 20:15:03 +00:00
Tilghman Lesher
aa158e2e46 Define ASTSBINDIR for script
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135482 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-04 17:07:52 +00:00
Tilghman Lesher
b0e9870535 Memory leak on unload
(closes issue #13231)
 Reported by: eliel
 Patches: 
       app_voicemail.leak.patch uploaded by eliel (license 64)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135479 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-04 16:56:19 +00:00
Russell Bryant
0b91843b15 Add a minor clarification to the documentation of mohinterpret and mohsuggest
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135473 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-04 16:26:17 +00:00
Michiel van Baak
c5ef42b87c make app_ices compile on OpenBSD.
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135058 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-01 11:43:46 +00:00
Michiel van Baak
3f2b34e888 fix some potential deadlocks in chan_skinny
(closes issue #13215)
Reported by: qwell
Patches:
      2008080100_bug13215.diff.txt uploaded by mvanbaak (license 7)
Tested by: mvanbaak


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@135055 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-08-01 10:55:27 +00:00
Kevin P. Fleming
192cadcd9d accomodate users who seem to lack a sense of humor :-)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134983 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-31 22:18:11 +00:00
Tilghman Lesher
da57d237e6 Specify codecs in callfiles and manager, to allow video calls to be set up
from callfiles and AMI.
(closes issue #9531)
 Reported by: Geisj
 Patches: 
       20080715__bug9531__1.4.diff.txt uploaded by Corydon76 (license 14)
       20080715__bug9531__1.6.0.diff.txt uploaded by Corydon76 (license 14)
 Tested by: Corydon76


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134976 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-31 21:53:19 +00:00
Russell Bryant
9105d1ecff Get app_ices working again
(closes issue #12981)
Reported by: dlogan
Patches:
      20080709__app_ices_v2_update_trunk.diff uploaded by bbryant (license 36)
      20080709__app_ices_v2_update_14.diff uploaded by bbryant (license 36)
Tested by: bbryant


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134915 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-31 19:37:26 +00:00
Steve Murphy
08450d1a93 (closes issue #11849)
Reported by: greyvoip
Tested by: murf

OK, a few days of debugging, a bunch of instrumentation
in chan_sip, main/channel.c, main/pbx.c, etc. and 5 solid 
notebook pages of notes later, I  have made the small
tweek necc. to get the start time right on the second 
CDR when:

  A Calls B
  B answ.
  A hits Xfer button on sip phone,
  A dials C and hits the OK button,
  A hangs up
  C answers ringing phone
  B and C converse
  B and/or C hangs up

But does not harm the scenario where:

  A Calls B
  B answ.
  B hits xfer button on sip phone,
  B dials C and hits the OK button,
  B hangs up
  C answers ringing phone
  A and C converse
  A and/or C hangs up

The difference in start times on the second CDR is because
of a Masquerade on the B channel when the xfer number is 
sent. It ends up replacing the CDR on the B channel with
a duplicate, which ends up getting tossed out. We keep 
a pointer to the first CDR, and update *that* after the
bridge closes. But, only if the CDR has changed.

I hope this change is specific enough not to muck
up any current CDR-based apps. In my defence, I 
assert that the previous information was wrong,
and this change fixes it, and possibly other
similar scenarios.

I wonder if I should be doing the same thing
for the channel, as I did for the peer, but
I can't think of a scenario this might affect.
I leave it, then, as an exersize for the users,
to find the scenario where the chan's CDR 
changes and loses the proper start time.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134883 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-31 19:23:42 +00:00
Russell Bryant
d90285f4f5 In case we have some processing threads that free more frames than they allocate,
do not let the frame cache grow forever.

(closes issue #13160)
Reported by: tavius
Tested by: tavius, russell


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134814 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-31 16:45:31 +00:00
Mark Michelson
f51e53921c Add more timeout checks into app_queue, specifically
targeting areas where an unknown and potentially
long time has just elapsed. Also added a check
to try_calling() to return early if the timeout
has elapsed instead of potentially setting a negative
timeout for the call (thus making it have *no* timeout
at all).


(closes issue #13186)
Reported by: miquel_cabrespina
Patches:
      13186.diff uploaded by putnopvut (license 60)
Tested by: miquel_cabrespina



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134758 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-31 15:56:18 +00:00
Tilghman Lesher
e5939d2f3e Oops, wrong define
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134704 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-30 22:39:57 +00:00
Steve Murphy
aaf314cf46 (closes issue #13197)
Reported by: pj

(closes issue #13051)
Reported by: pj

This patch substitutes commas in the expr 
supplied to the if () statement, as in
if ( expr ) ...

This solves both the bugs above, and makes
the source symmetric with switch statements,
which were earlier reported to need this sort
of treatment.

I tested this using the examples, both for
the compiler and at run time. Looks good.



git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134652 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-30 22:02:07 +00:00
Tilghman Lesher
ef03217c4b Qwell pointed out, via IRC, that the previous fix only worked when explicitly
set.  When nothing is set, and the option is implied, it breaks, because
configure sets the prefix to 'NONE'.  Fixing.


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134649 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-30 21:38:50 +00:00
Russell Bryant
a3bc8d9d7c Reduce stack consumption by 12.5% of the max stack size to fix a crash when
compiled with LOW_MEMORY.

(closes issue #13154)
Reported by: edantie


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134595 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-30 20:37:17 +00:00
Russell Bryant
7a5caf1a57 Fix a memory leak in func_curl. Every thread that used this function leaked
an allocation the size of a pointer.
(reported by jmls in #asterisk-dev)


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134540 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-30 19:52:53 +00:00
Tilghman Lesher
932ad2c19c Only override sysconfdir and mandir when prefix=/usr
(closes issue #13093)
 Reported by: pabelanger


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@134536 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2008-07-30 19:47:16 +00:00