dect
/
asterisk
Archived
13
0
Fork 0
Commit Graph

14237 Commits

Author SHA1 Message Date
mmichelson 1fd7575638 Fix a memory leak when reloading queue rules.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94547 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 20:30:05 +00:00
mmichelson d65ab00415 The one documentation source I forgot to update after the merge of the queue-penalty branch
was the CHANGES file. No longer!



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94546 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 20:28:04 +00:00
mmichelson b2262f0cc9 Lots of coding guidelines cleanup.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94545 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 20:24:24 +00:00
mmichelson 082024a258 Blocked revisions 94543 via svnmerge
........
r94543 | mmichelson | 2007-12-21 14:21:59 -0600 (Fri, 21 Dec 2007) | 3 lines

Bunch of coding guidelines cleanup


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94544 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 20:22:52 +00:00
mmichelson 25e8dd3093 Merged revisions 94540 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94540 | mmichelson | 2007-12-21 14:11:34 -0600 (Fri, 21 Dec 2007) | 8 lines

Better quota support for using IMAP storage voicemail

(closes issue #11415, reported by jaroth)
(closes issue #11152, reported by selsky)

Patch provided by jaroth


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94542 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 20:18:26 +00:00
qwell 7c0eb401e6 codecs.conf really shouldn't be mandatory.. it never had been before, so let's go back to being optional.
A big "thank you" to pnlarsson on IRC for allowing me access to his system to debug this.

Closes issue #11584.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94541 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 20:12:50 +00:00
mmichelson b2043fb3e3 Merged revisions 94538 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94538 | mmichelson | 2007-12-21 13:59:45 -0600 (Fri, 21 Dec 2007) | 5 lines

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)


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94539 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 20:01:10 +00:00
mmichelson 1c2f295df0 AST_LIST_REMOVE_CURRENT only takes one argument in trunk
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94516 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 17:40:44 +00:00
mmichelson 4b0258fbbe Merged revisions 94468 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94468 | mmichelson | 2007-12-21 10:49:35 -0600 (Fri, 21 Dec 2007) | 6 lines

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)


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94477 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 16:52:04 +00:00
russell 6aaafa095c Blocked revisions 94466 via svnmerge
........
r94466 | russell | 2007-12-21 10:37:47 -0600 (Fri, 21 Dec 2007) | 6 lines

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)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94467 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 16:42:52 +00:00
mmichelson 9fcb942ecb Merged revisions 94464 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94464 | mmichelson | 2007-12-21 10:11:44 -0600 (Fri, 21 Dec 2007) | 3 lines

Removing a debug message I accidentally just committed


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94465 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 16:12:14 +00:00
mmichelson 4d1324be79 Merged revisions 94420 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94420 | mmichelson | 2007-12-21 09:45:14 -0600 (Fri, 21 Dec 2007) | 5 lines

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)


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94463 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 16:10:21 +00:00
tilghman 5a731f4858 Merged revisions 94418 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94418 | tilghman | 2007-12-21 09:07:42 -0600 (Fri, 21 Dec 2007) | 2 lines

Fix for restart-as-user problem reported via the -dev list

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94419 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 15:14:52 +00:00
mmichelson 4bbec76368 Moved the update of the queue_ent's rule list to just before we try to call
queue members. This allows for the change in penalty levels to be executed at
the most logical time frame.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94396 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 01:14:32 +00:00
mmichelson f18c0943a0 Merging the queue-penalty branch. In short, this allows one to dynamically adjust
the QUEUE_MAX_PENALTY and the newly introduced QUEUE_MIN_PENALTY during a call depending
on the amount of time passed. The purpose is to allow the call to open up to more (or maybe
just different) members without the caller's losing his place in the queue. See 
configs/queuerules.conf.sample for an example of how to set up queue rules and configs/queues.conf.sample
for how to associate a rule with a queue.

Along with the functional changes, new CLI and manager commands exist to show the rules defined and
there is an additional CLI command to reload the queue rules.

Future enhancements that may be made: support for realtime queue rules and support for dynamically adding
a rule through the manager or CLI. Also a manager command to reload the queue rules (I'll probably write
this myself very soon).



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94370 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21 00:44:17 +00:00
mmichelson 6bdde69e79 The changes to header inclusion in trunk broke compilation of app_voicemail when using
IMAP storage. The reason is that c-client has its own definitions for LOG_WARNING
and LOG_DEBUG, so we need to be sure to include asterisk's definitions last so that
we use the proper values in app_voicemail.

(closes issue #11437, reported by blitzrage, patch suggested by blitzrage)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94345 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-20 23:43:24 +00:00
russell ac2a00d4a4 Add a bit more to the description of the "mwimonitor" option.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94320 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-20 22:39:39 +00:00
murf d3cbf26799 closes issue #11287; thanks to snuffy for this fix, which will surely make all solaris owners shout praises to his name.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94319 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-20 22:28:35 +00:00
russell 6ac2823852 Merged revisions 94256 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r94256 | russell | 2007-12-20 14:22:22 -0600 (Thu, 20 Dec 2007) | 13 lines

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

........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94257 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-20 20:25:05 +00:00
russell fefd98bdca Merged revisions 94251 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94251 | russell | 2007-12-20 14:08:42 -0600 (Thu, 20 Dec 2007) | 10 lines

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

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94252 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-20 20:16:21 +00:00
rizzo 91f1b6959d add some macros to simplify parsing the config file,
see description in config.h .

They are a variant of the set of macros i used in chan_oss.c,
structured in a way to be more robust to the presence of
spurious ';' - basically, they define wrappers for 'do {'
and '} while (0)', plus some helper functions to deal with simple
cases such as ast_copy_string, ast_malloc, strtoul, ast_true ...

The prefix (CV_ as 'Config Variable') tries to be easy to remember
and has been chosen to not conflict with other existing macros in the tree.

For the time being, I have only updated the three source files in the
tree that used the old M_* macros. Hopefully, more files will be
converted.

NOTE:

    I understand that inventing my own dialect of C is generally wrong;
    however, the lack of adequate support in the language encourages
    lazy programming practices (such as ignoring errors, bounds, etc.)
    and this increases the chance of vulnerability in the code, especially
    because we are parsing user input here.
    Hopefully, these macros and the use of ast_parse_arg (in config.h)
    should encourage the programmer to write more robust code.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94191 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-20 12:56:07 +00:00
rizzo 0a8518b7c8 modify http://svn.digium.com/view/asterisk?view=rev&rev=93603
so that paths and filename are writable by asterisk.c without
causing segfaults.

This involves defining the variables as const char *,
and having them point to as static, writable buffer
defined in asterisk.c

On passing, fix some errors in using these variables
in some files in utils/ , and in res/snmp/agent.c
which was redefining a variable without using paths.h

(not applicable to 1.4)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94168 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-20 09:55:05 +00:00
mmichelson 832aa00d11 1. Unify the check for a penalty < 0 into the set_member_penalty code.
2. Fix an error when checking the CLI command for setting a member's penalty.
3. Fix a logging error if the incorrect parameter was the queue name or interface.

(closes issue #11544, reported and patched by Laureano)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94124 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 23:17:42 +00:00
mmichelson 42d281c046 Merged revisions 94122 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94122 | mmichelson | 2007-12-19 17:02:22 -0600 (Wed, 19 Dec 2007) | 6 lines

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)


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94123 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 23:04:32 +00:00
russell 64ff93596e Merged revisions 94077 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r94077 | russell | 2007-12-19 16:48:48 -0600 (Wed, 19 Dec 2007) | 4 lines

Check for the existence of the soxmix application on the target platform and have
the result available in autoconfig.h.
(part of issue #11589)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94085 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 22:51:03 +00:00
tilghman a2c16ccd0b Add 'voicemail reload' command.
Reported by: eliel
Patch by: eliel
(Closes issue #11365)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94053 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 20:20:55 +00:00
tilghman 1d426245c8 Add contributed WaitUntil app.
Original code by pprindeville, updated for trunk by tilghman.
(Closes issue #11487)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94052 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 20:06:23 +00:00
russell 6a7bc1cd99 Add a couple of new time API calls - ast_tvdiff_sec and ast_tvdiff_usec
(closes issue #11270)
Reported by: dimas
Patches:
      tvdiff_us-4.patch uploaded by dimas (license 88)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94029 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 19:29:14 +00:00
rizzo f1c01a6797 Add instructions on how to generate your own font.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94002 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 17:58:39 +00:00
file 3e2036a7cd Merged revisions 93955 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r93955 | file | 2007-12-19 13:29:20 -0400 (Wed, 19 Dec 2007) | 2 lines

Make the 1.4 builders happy, ensure var is NULL.

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93956 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 17:31:29 +00:00
tilghman a64536a800 Merged revisions 93949 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r93949 | tilghman | 2007-12-19 11:04:13 -0600 (Wed, 19 Dec 2007) | 3 lines

Avoid segfault in chan_iax when peer isn't defined
(Closes issue #11602)

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93952 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 17:13:06 +00:00
rizzo 36be3451e8 Add a new API function, written at least twice in app_voicemail.c
and likely in other places too.

This is quite useful when placing mail/html stuff in config files.

 /*!
   \brief Convert some C escape sequences (\b\f\n\r\t) into the
        equivalent characters.
   \brief s The string to be converted (will be modified).
   \return The converted string.
  */
 char *ast_unescape_c(char *s);
 




git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93950 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 17:09:01 +00:00
rizzo 6016c98c2b add support for PARSE_DOUBLE, and remove identifiers for
types not supported (INT16 and UINT16)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93925 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 15:15:03 +00:00
oej c6314dd7de Reorganize CHANGES a bit. The "misc" section grew too large...
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93899 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 09:20:37 +00:00
rizzo 992d0b77a7 Properly document AST_EXT_TOOL_CHECK() and use it to check for
NETSMP and GTK (GTK is not used thoug).

AST_EXT_TOOL_CHECK() could be used for checking curl status
as well, perhaps with a small addition because we currently seem
to require a curl version greater than X.Y.Z

Add a NETSMP_INCLUDE entry in makeopts.in

We don't have yet any macros for using pkg-config to check
for a specific package (right now there is only gtk2+
in the category).




git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93898 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 08:57:45 +00:00
oej f93a8656aa Adding the ability to specify the To: header in an outbound INVITE
by adding an exclamation mark to the dial string.

This patch also exists for 1.4 in the fixtoheader-1.4 branch
and has been in production for quite some time.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93897 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 08:57:45 +00:00
rizzo 7c309cc622 make netsmp build under AST_DEVMODE. Description, included in the source,
is below. I should note that the PACKAGE_* macros that asterisk
defines in autoconfig.h are not used anywhere in the tree so
they should just be removed.

 /*
  * There is some collision collision between netsmp and asterisk names,
  * causing build under AST_DEVMODE to fail.
  *
  * The following PACKAGE_* macros are one place.
  * Also netsnmp has an improper check for HAVE_DMALLOC_H, using
  *    #if HAVE_DMALLOC_H   instead of #ifdef HAVE_DMALLOC_H
  * As a countermeasure we define it to 0, however this will fail
  * when the proper check is implemented.
  */

No


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93875 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 08:12:33 +00:00
oej 82835dcbcd Add option for starting remote Asterisk by naming the actual runtime socket instead of pointing
to configuration file with -C

Reported by: sobomax
Patches: 
      asterisk.c.diff.trunk uploaded by sobomax (license 359)
      doc changes by committer
(closes issue #11598)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93854 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 07:01:40 +00:00
dhubbard 7116d4562d add missing header file
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93827 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-19 00:09:05 +00:00
tilghman 8cfc775363 Making the canary error message a little more obvious.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93805 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 23:38:30 +00:00
tilghman 11a5516081 Add a canary process, for high priority mode (asterisk -p) to ensure that if
Asterisk goes into a busy loop, the machine will be recoverable.  We'd still
need to do a restart to put Asterisk back into high priority mode, but at
least a reboot won't be required. (Closes issue #11559)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93804 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 23:06:05 +00:00
qwell f3230e3b5b Blocked revisions 93764 via svnmerge
........
r93764 | qwell | 2007-12-18 16:42:41 -0600 (Tue, 18 Dec 2007) | 4 lines

FreeBSD also does not have byte swap functions.

Issue 11586, patch by sobomax.

........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93765 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 22:44:14 +00:00
oej 58d2c71f83 Move some warnings away to debug since some devices send a packet with a silly
string as a NAT keepalive packet.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93741 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 21:13:28 +00:00
tilghman 829520df6b Merged revisions 93668 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r93668 | tilghman | 2007-12-18 12:29:39 -0600 (Tue, 18 Dec 2007) | 10 lines

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)

........

................


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93672 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 18:39:25 +00:00
rizzo 5104b90faa remove a leftover line with only a '#' (wonder why
the compiler does not complain!) and variables that
are only used in asterisk.c



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93666 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 18:20:06 +00:00
mmichelson 8cf5108ca5 Merged revisions 93625 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r93625 | mmichelson | 2007-12-18 11:02:48 -0600 (Tue, 18 Dec 2007) | 6 lines

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)


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93626 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 17:05:19 +00:00
rizzo 553ab5f770 make configuration variable const so they are not accidentally
modified.
This requires casting the strings in asterisk.c when writing to
them, so we do it through a macro to do it consistently.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93603 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 10:24:58 +00:00
rizzo 659205253c remove unnecessary (char *) casts for ast_config_AST_* variables.
There are some left in the .flex files, left to the maintainer...



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93582 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 09:46:18 +00:00
rizzo 7a8342612d Rename the macros in defaults.h - they are not meant to be
globally visible.

Document the fact that DEFAULT_TMP_DIR cannot be overridden
from the default configuration (this needs to be fixed, as you
could have a totally different spooldir configured at runtime,
and yet DEFAULT_TMP_DIR keeps the compile-time default).

Remove two unused entries for sounds and images.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93581 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 09:26:03 +00:00
rizzo 0a965e2bdc make the code match documentation - now you can specify multiple
words in MODULE_PREFIX.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@93580 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-18 08:56:16 +00:00