aboutsummaryrefslogtreecommitdiffstats
path: root/main
AgeCommit message (Collapse)AuthorFilesLines
2006-12-19remove now useless extern declarations.rizzo1-2/+0
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48580 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-18convert the final clients of ast_build_string to use ast_str_*()rizzo3-13/+15
Now the only module left using it is chan_sip.c git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48559 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-18debugging shows that we always need more than 128 bytesrizzo1-2/+2
for the verbose and logging messages so start with a larger buffer from the beginning. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48558 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-18Merged revisions 48554 via svnmerge from kpfleming1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48554 | kpfleming | 2006-12-18 05:59:24 -0600 (Mon, 18 Dec 2006) | 3 lines remove some now-unnecessary explicit includes of autoconfig.h clean up per-file dependencies during 'make clean' ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48555 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-18Replace ast_build_string with ast_str_*().rizzo1-33/+28
On passing remove presumably duplicate code to generate the message for the manager_hooks: in the previous version, the message was almost the same as the one sent to regular sessions, with the exception of the empty line at the end, and a few (presumably unintentional) differences e.g. timestamps, debugging, and lowercase headers for "event" and "privilege". now we reuse the same message as before. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48553 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-16Merged revisions 48525 via svnmerge from kpfleming1-1/+0
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48525 | kpfleming | 2006-12-16 15:14:34 -0600 (Sat, 16 Dec 2006) | 2 lines simplify dependency tracking system, using the compiler's built-in method for generating them, and only doing dependency tracking if developer mode is enabled via the configure script ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48527 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-16Merged revisions 48521 via svnmerge from kpfleming1-5/+5
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48521 | kpfleming | 2006-12-16 14:12:41 -0600 (Sat, 16 Dec 2006) | 2 lines since we really, really have to have autoconfig.h included before all other headers (especially system headers), the Makefile will now force it to happen (this will fix build problems with files like ast_expr2f.c, where we can't control the inclusion order in the file itself) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48522 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-16forgot this part...rizzo1-11/+7
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48520 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-16another conversion from ast_build_str to ast_strrizzo1-13/+13
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48517 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-16convert ast_build_str to ast_str_*rizzo1-13/+10
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48516 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-16replace ast_build_string() with ast_str_*() functions.rizzo2-152/+135
This makes the code easier to follow and saves some copies to intermediate buffers. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48515 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15simplify the ast_dynamic_str_*.... routines byrizzo4-34/+34
renaming them to ast_str ... and putting the struct ast_threadstorage pointer into the struct ast_str. This makes the code a lot more readable. At this point we can use these routines also to replace ast_build_string(). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48510 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15move the dynamic string support in a better place i.e. string.hrizzo1-14/+30
While doing this, add a bit of documentation, and slightly extend the functionality as follows: + a max_len of -1 means that we take whatever the current size is, and never try to extend the buffer; + add support for alloca()-ted dynamic strings, which is very useful for all cases where we do an ast_build_string() now. Next step is to simplify the interface by using shorter names (e.g. ast_str as a prefix) and removing the _thread variant of the functions by saving the threadstorage reference into the struct ast_str. This can be done by overloading the 'type' field. Finally, I will do my best to remove the convoluted interface that results from trying to support platforms without va_copy(). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48509 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15Merged revisions 48506 via svnmerge from file1-41/+55
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48506 | file | 2006-12-15 14:55:28 -0500 (Fri, 15 Dec 2006) | 2 lines Turn payload_lock into bridge_lock and make it encompass all RTP structure contents that may relate to bridge information, including who we are bridged to. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48507 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15unbreak the output for http session.rizzo1-1/+1
Not long ago i replaced lseek() with fseek() but forgot that filr FILE's you need ftell to give you the current position. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48501 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15remove ast_safe_string_alloc() - it is completelyrizzo1-15/+0
equivalent to asprintf(). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48499 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15Doxygen changesoej1-0/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48491 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15constify ast_state2str() and note it is not reentrant.rizzo1-2/+4
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48477 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-15remove the macro LOAD_OH and expand it inline in the onlyrizzo1-1/+9
place where it was used. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48476 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-14Merged revisions 48472 via svnmerge from file1-11/+61
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48472 | file | 2006-12-14 12:36:12 -0500 (Thu, 14 Dec 2006) | 2 lines Payload values on the RTP structure can change AFTER a bridge has started. This comes from the packet handling of the SIP response when indication that it was answered has been sent. Therefore we need to protect this data with a lock when we read/write. (issue #8232 reported by tgrman) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48473 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-14Merged revisions 48461 via svnmerge from file1-75/+1
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48461 | file | 2006-12-13 22:33:30 -0500 (Wed, 13 Dec 2006) | 2 lines Remove direct RTCP bridging. I've come to the conclusion that we should handle this through the core and not just forward it on. Should solve a few bugs. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48462 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-13make sure that showdialplan sends only onerizzo1-14/+9
'Response: Success ' message even in case of a recursive call. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48459 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-13clean up function manager_show_dialplan_helper()rizzo1-126/+109
reducing indentation and normalizing loops. While doing this, remove some unused variables, fix an uninitialized string (idaction), and mark some places where the behaviour is not what we would expect (e.g. an empty context is reported as an error same as a non-existent one). Given that this function is not in 1.4, the above can be changed without too many backward compatibility concerns. Not applicable to 1.4 or below. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48458 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-12properly initialize a malloc'ed bufferrizzo1-0/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48410 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-12normalize the scanning of "general" options in the config file.rizzo1-63/+46
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48409 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-12Make sure tab-completion works even when we have typed a fullyrizzo1-3/+17
matching word (e.g. "sip<TAB>"); this is implemented by this one-line change - for (;; dst++, src += n) { + for (;src < argindex; dst++, src += n) { However this code is not exactly trivial to understand, so i am also adding some comments to help figuring out what it does. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48408 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-11make sure the argument to ast_malloc() is > 0.rizzo1-1/+1
Long explaination: The behaviour of the underlying malloc(0) differs depending on the operating system. Some return NULL (SysV behaviour); some still allocate a small chunk of memory and return a valid pointer (e.g. traditional BSD); some (e.g. FreeBSD 6.x) return a non-null pointer that causes a memory fault if used, even just for reading. Given the above variety, better never call malloc(0). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48389 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-11This update fixes the problem reported in bug 8551; that ast_app_getdata() ↵murf1-5/+7
behaves differently in trunk for the case of a null prompt. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48388 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-11Merged revisions 48381 via svnmerge from file1-36/+52
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48381 | file | 2006-12-11 00:36:45 -0500 (Mon, 11 Dec 2006) | 2 lines Merge in my latest RTP changes. Break out RTP and RTCP callback functions so they no longer share a common one. ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48383 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-07- Generalize the function ssl_setup() so that the certificate inforizzo2-53/+102
are passed as an argument. - Update the code in main/http.c to use the new interface (the diff is large but mostly mechanical, due to the name change of several variables); - And since now it is trivial, implement "AMI over TLS", and document the possible options in manager.conf - And since the test client (openssl s_client -connect host:port ) does not generate \r\n as a line terminator, make get_input() also accept just a \n as a line terminator (Mac users: do you also need the \r-only version ?) The option parsing in manager.conf is not very efficient, and needs to be cleaned up and made similar to what we have in http.conf git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48351 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-07Merged revisions ↵murf1-4/+7
47986,47995,47997,48001,48003-48004,48008-48014,48016,48018-48019 via svnmerge from https://origsvn.digium.com/svn/asterisk/trunk ................ r47986 | oej | 2006-11-24 07:00:19 -0700 (Fri, 24 Nov 2006) | 6 lines Doxygen update - Document cause codes - Document a bit more on channel variables - global, predefined and local - Fix some doxygen in channel.h. Adding one comment for two definitions does not work. They won't be copied to each. ................ r47995 | murf | 2006-11-24 10:40:49 -0700 (Fri, 24 Nov 2006) | 1 line This fix inspired by a patch supplied in bug 8189, which points out problems with the PLC code ................ r47997 | murf | 2006-11-24 11:17:25 -0700 (Fri, 24 Nov 2006) | 1 line removed the svnmerge-integrated property from trunk; it's confusing svnmerge in newly created branches ................ r48001 | rizzo | 2006-11-25 02:02:42 -0700 (Sat, 25 Nov 2006) | 5 lines set pointers to NULL after freeing memory to avoid multiple free() probably 1.4/1.2 issue as well if someone can look into that. ................ r48003 | oej | 2006-11-25 02:45:57 -0700 (Sat, 25 Nov 2006) | 9 lines - Adding comment on suspicious memory allocation. Seems like it's never freed, but I don't have a clear understanding of the frame allocation/deallocation, so I just mark this for investigation. (Reported by Ed Guy). We're trying to see if a free() hurts... - Doxygen comments on p2p rtp bridge stuff. I am a bit worried about shortcutting rtcp this way, but will need feedback from rtcp gurus. This should work for video calls too, and possibly UDPTL. ................ r48004 | oej | 2006-11-25 02:48:30 -0700 (Sat, 25 Nov 2006) | 2 lines Changing ERROR to lesser level. Imported from 1.2/1.4 ................ r48008 | rizzo | 2006-11-25 10:37:04 -0700 (Sat, 25 Nov 2006) | 7 lines generalize a bit the functions used to create an tcp socket and then run a service on it. The code in manager.c does essentially the same things, so we will be able to reuse the code in here (probably moving it to netsock.c or another appropriate library file). ................ r48009 | mattf | 2006-11-25 13:30:04 -0700 (Sat, 25 Nov 2006) | 1 line Updates to show linkset command ................ r48010 | mattf | 2006-11-25 13:54:38 -0700 (Sat, 25 Nov 2006) | 2 lines Add ss7 show linkset command ................ r48011 | mattf | 2006-11-25 14:32:33 -0700 (Sat, 25 Nov 2006) | 1 line Make sure we don't send a group reset on a group larger than 32 CICs ................ r48012 | mattf | 2006-11-25 14:35:23 -0700 (Sat, 25 Nov 2006) | 1 line bug fix ................ r48013 | mattf | 2006-11-25 14:46:58 -0700 (Sat, 25 Nov 2006) | 1 line Make compiler happier ................ r48014 | mattf | 2006-11-25 14:50:42 -0700 (Sat, 25 Nov 2006) | 1 line Little fix so we use the right message ................ r48016 | murf | 2006-11-25 17:15:42 -0700 (Sat, 25 Nov 2006) | 9 lines Merged revisions 48015 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48015 | murf | 2006-11-25 17:01:34 -0700 (Sat, 25 Nov 2006) | 1 line A little bit of func_cdr documentation upgrade-- no bug# involved, although 8221 may have inspired it. ........ ................ r48018 | murf | 2006-11-25 17:31:13 -0700 (Sat, 25 Nov 2006) | 9 lines Merged revisions 48017 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48017 | murf | 2006-11-25 17:26:16 -0700 (Sat, 25 Nov 2006) | 1 line might as well also document the raw values of the flag vars ........ ................ r48019 | russell | 2006-11-25 23:55:33 -0700 (Sat, 25 Nov 2006) | 6 lines - Add some comments on thread storage with a brief explanation of what it is as well as what the motivation is for using it. - Add a comment by the declaration of ast_inet_ntoa() noting that this function is not reentrant, and the result of a previous call to the function is no longer valid after calling it again. ................ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48350 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-06remove duplicated code to start the server threads, userizzo1-127/+61
the infrastructure exposed in http.c earlier today. As a bonus, now we can restart the session on a different port just reloading the module. On passing, fix a bug in the handling of 'enabled' in the configuration file - previously, a missing "enabled=" line in manager.conf meant "whatever the state was before" instead of a specific value. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48338 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-06Part of the transformations necessary to add TLS support,rizzo1-12/+52
as described in http://lists.digium.com/pipermail/asterisk-dev/2006-December/025213.html In detail, this commit does the following: b) change the function get_input() to use fread() instead of read() to collect the data. One can still do the ast_wait_for_input() on the original descriptor returned by accept(). c) change the function send_string() to work on the FILE *. As a side effect, this change now really guarantees that we don't spend more than "writetimeout" milliseconds on each line sent. d) modify the function action_command() so that it creates a temporary file descriptor to be passed to ast_cli_command(), and then read back the data from the temp file and write it to the output with send_string(). The code is similar to what is done in generic_http_callback() to support AMI-over-HTTP. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48332 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-06Make externally visible some generic code useful to createrizzo1-66/+3
and implement services over tcp and/or tcp-tls. This commit is nothing more than moving structure definitions (and documentation) from main/http.c to include/asterisk/http.h (temporary location until we find a better place), and removing the 'static' qualifier from server_root() and server_start(). The name change (adding the ast_ prefix as a minimum, and then possibly a more meaningful name) is postponed to future commits. Does not apply to other versions of asterisk. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48324 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-06Staticize one, and Constify a bunch of usage strings for CLI commands.russell7-22/+22
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48303 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-06Constify a bunch of the usage strings for CLI commands.russell2-20/+20
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48302 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-05Doxygen updatesoej1-1/+28
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48277 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-05Expand on r48273 (from issue 8506), to translate more of the fskmodem stuff ↵qwell3-27/+27
to English. r48273 dealt with the comments and such, this deals with the code itself. (This couldn't have been easily done if it weren't for 48273 - thanks again for that merbanan) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48276 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-05Issue #8506 - translate spanish comments in fskmodem to english (according ↵oej1-33/+32
to bug guidelines) Thanks merbanan! git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48273 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-05Well, yes... oej2-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48259 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-05Reserving flags for coming code (currently in the "videocaps" branch) oej2-0/+6
implementing T.140 support in RTP. T.140/RFC 4351 is TDD over IP - text telephony for hearing impaired. It defines a realtime text chat, much like the old "talk" application in Unix. T.140 is character by character in real time. It's not the same as our current MESSAGE format - that is more like IM, but can be gatewayed to MESSAGE with a text "codec" if needed. More patches will follow, as soon as we've separated this code from the video capabilities functions in the videocaps branch. Code by John Martin, Aupix (disclaimer on file) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48258 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-02- Code formattingoej5-137/+174
- remove coef_in.h and coef_out.h that was only included as data definitions in fskmodem.c If you understand spanish, please help us translate the comments in fskmodem.c. Thanks! git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48205 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-02- Disable RTP timeouts during T.38 transmissionoej1-0/+52
- Encapsulate RTP timers to the RTP structure, so we have one set for video and one for audio - Document RTP keepalive configuration option - Cleanup and document the monitor support function to hangup on RTP timeouts - Add RTP keepalive to SIP show settings Imported from 1.4 with modifications for trunk. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48200 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-01Formatting fixoej1-3/+3
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48188 f38db490-d61c-443f-a65b-d21fe96a405b
2006-12-01Merged revisions 48179 via svnmerge from tilghman1-1/+0
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48179 | tilghman | 2006-12-01 13:38:59 -0600 (Fri, 01 Dec 2006) | 2 lines Double-unlock error (reported by blitzrage on IRC) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48180 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-30Merged revisions 48168 via svnmerge from file1-2/+8
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r48168 | file | 2006-11-30 16:18:24 -0500 (Thu, 30 Nov 2006) | 2 lines Do not do a partial bridge for Google Talk since we need to handle STUN. (issue #8448 reported by phsultan) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48169 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-30Documentation updatesoej2-2/+21
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48164 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-30Merged revisions 48152 via svnmerge from file1-5/+5
https://origsvn.digium.com/svn/asterisk/branches/1.4 ................ r48152 | file | 2006-11-30 13:47:40 -0500 (Thu, 30 Nov 2006) | 10 lines Merged revisions 48151 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r48151 | file | 2006-11-30 13:42:45 -0500 (Thu, 30 Nov 2006) | 2 lines Print certain CDR messages out at the NOTICE level versus WARNING since they can occur when used with the CDR applications and are perfectly fine. (issue #8367 reported by dartvader) ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48153 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-30Small updateoej1-0/+6
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48150 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-30Doxygen updatesoej1-1/+19
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@48149 f38db490-d61c-443f-a65b-d21fe96a405b