summaryrefslogtreecommitdiff
path: root/utils.c
AgeCommit message (Collapse)Author
2006-06-07simplify autoconfig include mechanism (make tholo happy he can use lint ↵Kevin P. Fleming
again :-) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@32846 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-01changes for base64 to work in multiline instancesMatt O'Gorman
as well as being more efficient, patch from jcollie's base64 branch git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@31492 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-06-01fix an incorrect comment (issue #7259, tardieu)Russell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@31360 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-05move ast_carefulwrite from manager.c to utils.c so that cli.c andRussell Bryant
res_agi.c no longer depend on manager.h (issue #6397, casper) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25026 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-05-05use ast_malloc instead of mallocRussell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@24880 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-12add 'show threads' and 'show profile' commands.Luigi Rizzo
These are momstly debugging tools for developers, a bit documented in the header files (utils.h), although more documentation is definitely necessary. The performance impact is close to zero(*) so there is no need to compile it conditionally. (*) not completely true - thread destruction still needs to search a list _but_ this can be easily optimized if we end up with hundreds of active threads (in which case, though, the problem is clearly elsewhere). git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@19544 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-04-10Bug 6829 - asprintf for SolarisTilghman Lesher
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@18755 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-30initial implementation of support for native atomic ops.Luigi Rizzo
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@16601 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-23don't wrap this in ifdef... using va_start is safe on all platforms :-)Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@14479 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-07Doxygen changesOlle Johansson
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@12344 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-03-06Portability issue - make stringfields work on FreeBSD 4.x (oej/rizzo)Olle Johansson
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@12012 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-02-23add 'consumed' argument to ast_get_time_t, so callers can know how many ↵Kevin P. Fleming
characters were used in the parser update pbx_dundi to use ast_get_time_t eliminate some compiler warnings git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@10871 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-02-15add API function for parsing strings to time_t (issue #6320, with mods)Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@10105 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-02-11eliminate warning on older versions of gccRussell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@9629 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-02-03Bug 6322 - Implementation of SHA1 in Asterisk (plus dialplan function to use it)Tilghman Lesher
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@9138 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-26string field manager improvements:Kevin P. Fleming
use multiple memory blocks, instead of realloc(), ensuring that field pointers will never become invalid or change don't run vs(n)printf twice when doing a field build unless required git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@8697 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-10Declare missing randomlockOlle Johansson
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7936 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-10Bug 5961 - new RAND() functionTilghman Lesher
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7920 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-06ensure that string field 'build' operation only evaluates arguments one timeKevin P. Fleming
fix some minor documentation errors return proper type from string field space allocator git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7841 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2006-01-04add memory-pool based string field management for structuresKevin P. Fleming
convert chan_sip sip_pvt and sip_registry structures to use string fields add 'const' qualifiers to a few API calls that don't modify their input strings add an asprintf() wrapper to astmm git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7797 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-12-20- move the string join() function to utils.c since it is used in both cli.c ↵Russell Bryant
and res_agi.c - reimplement ast_join to be of linear effieciency instead of quadratic - remove some useless checks for "if (e)" - reorder checks for strings starting with '_' to avoid a useless call to ast_join() - check array bounds when parsing arguments to AGI (issue #5868) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7556 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-12-13Merged revisions 7468 via svnmerge from Kevin P. Fleming
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r7468 | kpfleming | 2005-12-13 10:06:27 -0600 (Tue, 13 Dec 2005) | 2 lines correct broken math in tvfix() for timestamp values over one million ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7469 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-11-29remove extraneous svn:executable propertiesKevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7221 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-11-08issue #5569 minus lock.h changesKevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7024 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-11-01issue #4678Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6936 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-11-01issue #5549Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6930 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-31provide an alternate getloadavg implementation and a fallback for systems ↵Kevin P. Fleming
that don't have it at all (issue #5549 with minor mods) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6903 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-31silence compiler warningKevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6898 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-26change ast_strlen_zero to also check for the string to be definedRussell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6862 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-26remove duplicate headerRussell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6859 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-26more doxygenification (issue #5513)Russell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6852 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-24Doxygen documentation update from oej (issue #5505)Russell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6847 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-21Fix segfault in CVS head (sorry about that)Mark Spencer
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6839 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-21Be sure to avoid octal interpretations of IP's (bug #5477)Mark Spencer
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6838 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-16More utility cleanupsMark Spencer
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6798 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-10-01add ast_build_string_va(), which accepts a varargs list directlyKevin P. Fleming
ensure the _entire_ manager_event() output is either queued or sent via ast_carefulwrite() git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6708 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-09-29ensure scheduling priority is inherited into new threads (issue #5293)Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6692 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-09-23move process_quotes_and_slashes to utils.c since it is used by both pbx_ael ↵Russell Bryant
and pbx_config clean up some formatting remove some commented out reference code move unload_module in pbx_ael down to be with the rest of the standard module functions git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6630 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-09-14update MANY more files with proper copyright/license info (thanks Ian!)Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6596 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-09-14don't double define our own string functions on platforms that don't have ↵Kevin P. Fleming
them (issue #5169) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6587 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-09-02fix a couple of warnings on osxRussell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6500 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-08-29encode/decode URIs in 'pedantic' mode (issue #3923)Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6441 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-08-23make the warning message be LOG_WARNING (issue #4960)Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6388 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-08-07more fixes for gcc4 warnings ...Russell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6298 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-08-03Fix solaris vasprintf (don't free the memory, duh) (bug #4890)Mark Spencer
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6271 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-08-03Fix vasnprintf emulation (bug #4882)Mark Spencer
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6258 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-07-20move strtoq into new string files (bug #4740)Kevin P. Fleming
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6171 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-07-19restore warning about negative timestamps now that it is fixedRussell Bryant
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6161 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-07-19suppress timestamp message until we can figure out where it is coming from,Russell Bryant
since it appears that this isn't causing a real problem git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6159 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2005-07-15add a library of timeval manipulation functions, and change a large number ↵Kevin P. Fleming
of usses to use the new functions (bug #4504) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6146 65c4cc65-6c06-0410-ace0-fbb531ad65f3