dect
/
asterisk
Archived
13
0
Fork 0
Commit Graph

13927 Commits

Author SHA1 Message Date
rizzo 992c109dc4 Implement the outcome of a discussion on the -dev list re. the use
of DESTDIR and INSTALL_PATH - many thanks to Tzafrir Cohen and
Simon Perreault for extremely useful feedback:
 
1. comment out the [directories] section the created asterisk.conf ;
   you can set the correct defaults at build time using INSTALL_PATH,
   so the repetition here is redundant and often wrong.
   (The next step now is move asterisk.conf outside the Makefile to
   asterisk.conf.sample, because there is little if anything here
   that needs to be constructed at build/install time).
 
2. use DESTDIR?=$(INSTALL_PATH) so you only need to specify a path
   once if the two coincide. This should have no ill side effects, 
   because if you don't specify DESTDIR, you really need
   INSTALL_PATH="" to set the correct defaults, and if you specify
   DESTDIR the value is not overridden.

The second part required moving the 'export DESTDIR' right after
the assignment to prevent DESTDIR getting set by the export 
(this is documented in the Makefile).o hopefully avoid the mistake)$

With this change you can now do something like this from your source tree:

	make INSTALL_PATH=/some/place install samples

and then

	main/asterisk -vdc

which will pick up the correct config files and libraries from
/some/place - i.e. great for developers!



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@92002 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-09 16:47:25 +00:00
rizzo 3f42ded149 remove unused code, and simplify the logic for #include/#exec
(still a lot of cleanup needed here).



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91983 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 19:06:01 +00:00
rizzo 14f66c1347 Implement comment_buffer and lline_buffer in terms of the ast_str_*() API.
I don't know if comment_buffers etc are actually used at all...



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91962 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 18:50:32 +00:00
rizzo 0baa4ebe7d unify some common code
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91953 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 18:18:28 +00:00
rizzo f795414e69 normalize formatting
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91952 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 18:05:42 +00:00
rizzo b4a97437e3 document a nice technique to exit from a block in case of errors.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91951 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 17:58:08 +00:00
rizzo 385fb74486 a little bit of documentation on how lines are parsed.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91931 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 03:47:19 +00:00
rizzo 0c67039eb1 normalize header order, and add a comment on the need
to clean up this file.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91930 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 03:27:16 +00:00
rizzo 6ee4d56b30 some platforms (e.g. FreeBSD4) need netinet/in.h to be included
before arpa/inet.h



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91929 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-08 03:26:09 +00:00
qwell 2d63a111de Merged revisions 91890 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

(closes issue #11273)
........
r91890 | qwell | 2007-12-07 17:29:01 -0600 (Fri, 07 Dec 2007) | 4 lines

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.

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91891 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 23:32:09 +00:00
qwell db1a68bf29 Update documentation for pbx_lua.
Closes issue #11492, patch by mnicholson.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91832 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 21:28:49 +00:00
russell f37338b8d4 Merged revisions 91830 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91830 | russell | 2007-12-07 15:24:33 -0600 (Fri, 07 Dec 2007) | 5 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91831 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 21:25:03 +00:00
russell 3a09aaa380 Merged revisions 91828 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91828 | russell | 2007-12-07 15:17:24 -0600 (Fri, 07 Dec 2007) | 6 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91829 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 21:17:52 +00:00
russell e129f64bc2 Merged revisions 91826 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91826 | russell | 2007-12-07 15:11:08 -0600 (Fri, 07 Dec 2007) | 6 lines

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.

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91827 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 21:11:44 +00:00
russell 087a51990d Merged revisions 91783 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91783 | russell | 2007-12-07 10:38:48 -0600 (Fri, 07 Dec 2007) | 6 lines

* 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

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91784 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 16:40:41 +00:00
qwell ba7dec1f6d Fix a small typo in a comment.
Closes issue #11490


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91782 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 16:37:36 +00:00
russell d3dbd5cddd Merged revisions 91780 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91780 | russell | 2007-12-07 10:25:25 -0600 (Fri, 07 Dec 2007) | 7 lines

* 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.

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91781 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 16:28:36 +00:00
qwell 20476ae522 Add count of total number of calls processed by asterisk during it's lifetime.
Add number of total calls and current calls to SNMP.

Closes issue #10057, patch by jcmoore.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91779 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 16:11:05 +00:00
russell 2db1dbb003 Merged revisions 91777 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91777 | russell | 2007-12-07 10:08:35 -0600 (Fri, 07 Dec 2007) | 6 lines

* 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.

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91778 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 16:11:00 +00:00
mmichelson f8664dceba Merged revisions 91737 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91737 | mmichelson | 2007-12-07 09:39:58 -0600 (Fri, 07 Dec 2007) | 7 lines

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)


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91738 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 15:40:59 +00:00
russell a3c8389dc9 Merged revisions 91693 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91693 | russell | 2007-12-06 20:51:22 -0600 (Thu, 06 Dec 2007) | 2 lines

Don't unlock the dialed_interfaces list until we're done messing with the iterator.

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91700 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 02:52:38 +00:00
russell 7f34a61cec Merged revisions 91677 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91677 | russell | 2007-12-06 20:38:40 -0600 (Thu, 06 Dec 2007) | 4 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91678 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 02:43:21 +00:00
russell 8accb5e1d0 Merged revisions 91675 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91675 | russell | 2007-12-06 20:19:45 -0600 (Thu, 06 Dec 2007) | 7 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91676 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 02:21:07 +00:00
tilghman d5f961dfd6 Merged revisions 91637 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91637 | tilghman | 2007-12-06 18:52:17 -0600 (Thu, 06 Dec 2007) | 5 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91638 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-07 00:58:52 +00:00
tilghman bb15c2571f Add a manager event for PRI events: this will help manager users detect when a D-channel goes down
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91618 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 23:47:07 +00:00
tilghman 253f4f70fb If duration or billsec are not yet calculated, calculate them on demand.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91617 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 23:27:46 +00:00
qwell 21ea51e69a Fix a problem with quoting in sqlite3 cdr module..
Closes issue #11070, patch by seanbright.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91598 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 21:57:28 +00:00
mmichelson df690ef26f Handle allocation failure of the heard and deleted arrays of the vm_state.
(closes issue #11408, reported and patched by jaroth)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91579 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 21:03:15 +00:00
tilghman ee6901bb3c Merged revisions 90166,90736,90753 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r90166 | tilghman | 2007-11-29 13:48:10 -0600 (Thu, 29 Nov 2007) | 3 lines

Properly escape cdr->src and cdr->dst and ensure we use thread-safe escaping
(Fixes AST-2007-026)

........
r90736 | tilghman | 2007-12-03 17:23:55 -0600 (Mon, 03 Dec 2007) | 5 lines

If both dbhost and dbsock were not set, a NULL deref could result
Reported by: xrg
Patch by: tilghman
(Closes issue #11387)

........
r90753 | tilghman | 2007-12-03 17:50:51 -0600 (Mon, 03 Dec 2007) | 5 lines

Solaris requires the inclusion of sys/loadavg.h for getloadavg().
Reported by: snuffy
Patch by: snuffy,tilghman
(Closes issue #11430)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91561 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 20:52:26 +00:00
russell abcd262323 Blocked revisions 91501 via svnmerge
........
r91501 | russell | 2007-12-06 13:11:35 -0600 (Thu, 06 Dec 2007) | 5 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91502 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 19:12:54 +00:00
mattf e80ac8df81 Make sure we clear these flags when libpri is not installed
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91472 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 16:54:08 +00:00
file 98edafc63c Merged revisions 91450 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91450 | file | 2007-12-06 12:49:42 -0400 (Thu, 06 Dec 2007) | 6 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91458 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 16:51:09 +00:00
file db370b01e9 Merged revisions 91439 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91439 | file | 2007-12-06 12:14:26 -0400 (Thu, 06 Dec 2007) | 4 lines

Add support for accepting and sending T.38 in the initial INVITE.
(closes issue #9402)
Reported by: thdei

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91440 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 16:18:49 +00:00
oej 283b5f3ef0 Adding documentation for the massive manager changes to manager
version 1.1 - hopefully a more consistent manager interface.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91438 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 15:56:58 +00:00
oej 119bb09f05 - The Ping Action
- Now use Response: success
        - New header "Ping: pong" :-)

- The Events action
        - Now use Response: Success
        - The new status is reported as "Events: On" or "Events: Off"

- Report if manager is enabled in the reload event

Small cleanups...

From moremanager


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91420 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 15:50:43 +00:00
oej e8a2112e1c Changes to manager events in channel.c
- Newstate event
        - Now has "CalleridNum" for numeric caller id, like Newchannel
        - The event does not send "<unknown>" for unknown caller IDs just an empty field
- Newstate and Newchannel events
        - these have changed headers
        "State"         -> ChannelStateDesc     Text based channel state
                        -> ChannelState         Numeric channel state
        - The events does not send "<unknown>" for unknown caller IDs just an empty field

- Newstate event
        - Now has "CalleridNum" for numeric caller id, like Newchannel
        - The event does not send "<unknown>" for unknown caller IDs just an empty field

- Link and Unlink events
        - The "Link" and "Unlink" bridge events in channel.c are now renamed to "Bridge"
        - The link state is in the bridgestate: header as "Link" or "Unlink"
        - For channel.c bridges, "Bridgetype: core" is added. This opens up for
          bridge events in rtp.c and channel drivers

- The "Rename" manager event has a renamed header, to use the same
        terminology for the current channel as other events
        - Oldname       -> Channel

(Moremanager)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91409 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 15:29:05 +00:00
oej 1a53ecf2d8 New manager event when a channel changes account code.
Maybe belongs in the new cdr category?
---moremanager---

 Event: NewAccountCode
        Modules: cdr.c
        Purpose: To report a change in account code for a live channel
        Example:
                Event: NewAccountCode
                Privilege: call,all
                Channel: SIP/olle-01844600
                Uniqueid: 1177530895.2
                AccountCode: Stinas account 1234848484
                OldAccountCode: Olles Account 12345



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91408 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 15:12:18 +00:00
oej 6d98f4fd7e - Dial event
- Event Dial has new headers, to comply with other events
        - Source        -> Channel              Channel name (caller)
        - SrcUniqueID   -> UniqueID             Uniqueid
        (new)           -> Dialstring           Dialstring in app data


(moremanager)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91407 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 15:04:34 +00:00
oej 526275407d Adding small missing but important comma...
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91406 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 14:55:31 +00:00
oej 7c7bfe6daf A big oops...
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91388 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 14:40:44 +00:00
oej 77a2479f53 The MeetmeJoin now has caller ID name and Caller ID number fields (like MeetMeLeave)
(Moremanager)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91387 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 14:36:54 +00:00
oej 05ba99e36b Update ZapShowChannels so that you can specify one channel.
Action ZapShowChannels
        Header changes
        - Channel:      -> ZapChannel
        For active channels, the Channel: and Uniqueid: headers are added
        You can now add a "ZapChannel: " argument to zapshowchannels actions
        to only get information about one channel.

From the moremanager branch


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91386 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 14:33:14 +00:00
oej e9f4991f30 Doxygen updates
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91385 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 14:29:20 +00:00
oej 4f471e1f71 Merged revisions 91366 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91366 | oej | 2007-12-06 13:54:11 +0100 (Tor, 06 Dec 2007) | 4 lines

Make sure logger is reloaded at general reload in the cli.

(Discovered during Asterisk training in Portugal)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91384 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 14:23:12 +00:00
oej 21f8732bd3 Change description of new manager command
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91348 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 10:29:02 +00:00
oej 9a86564730 Add manager command for showing all current channels.
Thanks, eliel, for writing the original patch. Modified by me to follow
other manager events and the new "moremanager" style.

(closes issue #11478)
Reported by: eliel
Patches: 
      manager.c.patch uploaded by eliel (license 64)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91347 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 10:27:54 +00:00
file 1b34ebf274 Instead of iterating through the entire epoll events array just look at the ones that will actually contain data. (props to eliel on IRC for this)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91328 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-06 04:37:36 +00:00
mmichelson 67e82aa1ba Merged revisions 91292 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91292 | mmichelson | 2007-12-05 16:57:13 -0600 (Wed, 05 Dec 2007) | 3 lines

Reverting extra stuff I didn't mean to commit


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91293 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-05 22:57:57 +00:00
mmichelson eedde68808 Merged revisions 91273 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91273 | mmichelson | 2007-12-05 16:35:52 -0600 (Wed, 05 Dec 2007) | 11 lines

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)


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91291 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-05 22:55:49 +00:00
tilghman 747e06552c Merged revisions 91237 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r91237 | tilghman | 2007-12-05 15:38:13 -0600 (Wed, 05 Dec 2007) | 2 lines

Upgrade to the latest version of extra sounds

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@91238 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-05 21:46:42 +00:00