aboutsummaryrefslogtreecommitdiffstats
path: root/res/res_config_sqlite.c
AgeCommit message (Collapse)AuthorFilesLines
2009-08-10AST-2009-005tilghman1-1/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@211539 f38db490-d61c-443f-a65b-d21fe96a405b
2009-03-18a few more namespace updates... res_ael_share still needs some work before ↵kpfleming1-1/+1
this can be merged to other release branches git-svn-id: http://svn.digium.com/svn/asterisk/trunk@182848 f38db490-d61c-443f-a65b-d21fe96a405b
2009-02-05Change the first field, or we don't get the necessary field separation.tilghman1-0/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@173657 f38db490-d61c-443f-a65b-d21fe96a405b
2008-12-13Merge ast_str_opaque branch (discontinue usage of ast_str internals)tilghman1-12/+11
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@163991 f38db490-d61c-443f-a65b-d21fe96a405b
2008-12-05Janitor, use ARRAY_LEN() when possible.eliel1-2/+2
(closes issue #13990) Reported by: eliel Patches: array_len.diff uploaded by eliel (license 64) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@161218 f38db490-d61c-443f-a65b-d21fe96a405b
2008-11-29we can now build with -Wformat=2, which found a couple of real bugskpfleming1-7/+6
because SPRINTF() use non-literal format strings (which cannot be checked), move it into its own module so the rest of func_strings can benefit from format string checking git-svn-id: http://svn.digium.com/svn/asterisk/trunk@159774 f38db490-d61c-443f-a65b-d21fe96a405b
2008-11-02bring over all the fixes for the warnings found by gcc 4.3.x from the 1.4 ↵kpfleming1-1/+4
branch, and add the ones needed for all the new code here too git-svn-id: http://svn.digium.com/svn/asterisk/trunk@153616 f38db490-d61c-443f-a65b-d21fe96a405b
2008-10-14Merge realtime_update2 branch, which adds a new realtime API call namedtilghman1-16/+97
'update2', which permits updates which match across multiple columns, instead of requiring all tables to have a single unique identifier. All of the other API calls with the exception of 'update' already had the ability to match on multiple fields, so it was a missing and very desireable feature that an API call implementing an update should have this, too. This does not change any outward performance of Asterisk, but it should make life easier for application developers who use the RealTime framework. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@148570 f38db490-d61c-443f-a65b-d21fe96a405b
2008-10-10Don't include logger.h in asterisk.h by default as it is causing problems ↵seanbright1-0/+1
building app_voicemail. Instead, include it where it is needed. This turned out to be a relatively minor issue because other headers include logger.h as well. Need to test -addons before merging this back to 1.6.0. (closes issue #13605) Reported by: tomo1657 Patches: 13605_seanbright.diff uploaded by seanbright (license 71) Tested by: mmichelson git-svn-id: http://svn.digium.com/svn/asterisk/trunk@148200 f38db490-d61c-443f-a65b-d21fe96a405b
2008-09-12Create a new config file status, CONFIG_STATUS_FILEINVALID for differentiatingtilghman1-1/+1
when a file is invalid from when a file is missing. This is most important when we have two configuration files. Consider the following example: Old system: sip.conf users.conf Old result New result ======== ========== ========== ========== Missing Missing SIP doesn't load SIP doesn't load Missing OK SIP doesn't load SIP doesn't load Missing Invalid SIP doesn't load SIP doesn't load OK Missing SIP loads SIP loads OK OK SIP loads SIP loads OK Invalid SIP loads incompletely SIP doesn't load Invalid Missing SIP doesn't load SIP doesn't load Invalid OK SIP doesn't load SIP doesn't load Invalid Invalid SIP doesn't load SIP doesn't load So in the case when users.conf doesn't load because there's a typo that disrupts the syntax, we may only partially load users, instead of failing with an error, which may cause some calls not to get processed. Worse yet, the old system would do this with no indication that anything was even wrong. (closes issue #10690) Reported by: dtyoo Patches: 20080716__bug10690.diff.txt uploaded by Corydon76 (license 14) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@142992 f38db490-d61c-443f-a65b-d21fe96a405b
2008-07-31Switch command order, to meet with current specstilghman1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@134977 f38db490-d61c-443f-a65b-d21fe96a405b
2008-07-31Two errors:tilghman1-23/+32
1) If a function returns SQLITE_LOCKED, no recovery is possible. 2) An error message can be allocated, even when no error is signalled. (closes issue #13109) Reported by: gknispel_proformatique git-svn-id: http://svn.digium.com/svn/asterisk/trunk@134919 f38db490-d61c-443f-a65b-d21fe96a405b
2008-07-30Add adaptive capabilities to the sqlite realtime drivertilghman1-60/+299
(closes issue #13097) Reported by: gknispel_proformatique Patches: 20080730__bug13097.diff.txt uploaded by Corydon76 (license 14) Tested by: Corydon76 git-svn-id: http://svn.digium.com/svn/asterisk/trunk@134442 f38db490-d61c-443f-a65b-d21fe96a405b
2008-07-19fix a couple of comments in sqlite resource driver.mvanbaak1-10/+4
(closes issue #13110) Reported by: gknispel_proformatique Patches: res_config_sqlite_comments.patch uploaded by gknispel (license 261) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@132277 f38db490-d61c-443f-a65b-d21fe96a405b
2008-07-17Fix memory leakstilghman1-0/+6
(closes issue #13099) Reported by: gknispel_proformatique Patches: res_config_sqlite_leak_on_error.patch uploaded by gknispel (license 261) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@131753 f38db490-d61c-443f-a65b-d21fe96a405b
2008-07-17Fix memory leak.tilghman1-0/+1
(Closes issue #13096) Reported by gknispel_proformatique git-svn-id: http://svn.digium.com/svn/asterisk/trunk@131681 f38db490-d61c-443f-a65b-d21fe96a405b
2008-07-16Don't try to dereference the dbfile pointer ifmmichelson1-1/+1
we know that it's NULL. (closes issue #13092) Reported by: gknispel_proformatique Patches: trunk_sqlite_check_vars_null.patch uploaded by gknispel (license 261) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@131361 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-31Initialize all these here tmp pointers at declaration. They confused some ↵file1-4/+3
compilers a wee bit. (closes issue #12333) Reported by: ovi git-svn-id: http://svn.digium.com/svn/asterisk/trunk@111961 f38db490-d61c-443f-a65b-d21fe96a405b
2008-03-11An offhand comment from Russell made me realize that the configuration filetilghman1-3/+5
caching would not work properly for users.conf and any other file read from more than one place. I needed to add the filename which requested the config file to get it to work properly. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@107791 f38db490-d61c-443f-a65b-d21fe96a405b
2007-12-21Store dates using local time instead of UTCmmichelson1-3/+3
(closes issue #11610, reported and patched by rbraun_performatique) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@94548 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-21remove a bunch of useless #include "options.h"rizzo1-1/+0
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89511 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-19include "logger.h" and errno.h from asterisk.h - usage shows that theyrizzo1-1/+0
were included almost everywhere. Remove some of the instances. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89424 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-16Start untangling header inclusion in a way that does not affectrizzo1-4/+0
build times - tested, there is no measureable difference before and after this commit. In this change: use asterisk/compat.h to include a small set of system headers: inttypes.h, unistd.h, stddef.h, stddint.h, sys/types.h, stdarg.h, stdlib.h, alloca.h, stdio.h Where available, the inclusion is conditional on HAVE_FOO_H as determined by autoconf. Normally, source files should not include any of the above system headers, and instead use either "asterisk.h" or "asterisk/compat.h" which does it better. For the time being I have left alone second-level directories (main/db1-ast, etc.). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89333 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-14One more typo in config.c; and missed conversions due to the constifying of ↵tilghman1-2/+2
ast_variable_new parameters git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89270 f38db490-d61c-443f-a65b-d21fe96a405b
2007-11-12Doxygen fixes.qwell1-3/+3
Also fix a common typo I kept seeing (arguement) in various files. Closes issue #11222, patch by snuffy (with arguement > argument by me). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@89202 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-25closes issue #11045 - each file needs to define ASTERISK_FILE_VERSION, if ↵murf1-0/+1
you are going to set MTX_PROFILE in the compiler flags; the problem was that the fixes were getting made to the generated .c file, and erased the next time someone regenerated that file from the corresponding .y or .flex file. Moral of story: keep your eyes open and make mods to the .y (or flex input file) and re-run bison (or flex) as the Makefile directs for that file, and then check in both. Also, res_config_sqlite was kinda missed, and has the same issue. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@87024 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-22Switch from AST_CLI (formerly NEW_CLI) to AST_CLI_DEFINE, since the former ↵qwell1-1/+1
didn't make much sense git-svn-id: http://svn.digium.com/svn/asterisk/trunk@86820 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-19Convert NEW_CLI to AST_CLI.qwell1-1/+1
Closes issue #11039, as suggested by seanbright. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@86536 f38db490-d61c-443f-a65b-d21fe96a405b
2007-10-19More changes to NEW_CLI.qwell1-23/+28
Also fixes a few cli messages and some minor formatting. (closes issue #11001) Reported by: seanbright Patches: newcli.1.patch uploaded by seanbright (license 71) newcli.2.patch uploaded by seanbright (license 71) newcli.4.patch uploaded by seanbright (license 71) newcli.5.patch uploaded by seanbright (license 71) newcli.6.patch uploaded by seanbright (license 71) newcli.7.patch uploaded by seanbright (license 71) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@86534 f38db490-d61c-443f-a65b-d21fe96a405b
2007-09-17Add support for #include, var_metric, and cat_metric in res_config_sqliterussell1-1/+21
(closes issue #10738, rbraun_proformatique) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@82679 f38db490-d61c-443f-a65b-d21fe96a405b
2007-09-13Various code and documentation cleanups for res_config_sqliterussell1-244/+252
(closes issue #10711, rbraun_proformatique) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@82321 f38db490-d61c-443f-a65b-d21fe96a405b
2007-09-05Doxygen cleanups/fixes.qwell1-1/+2
Closes issue #10654, patch by snuffy git-svn-id: http://svn.digium.com/svn/asterisk/trunk@81560 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-29This code was in team/murf/bug8684-trunk; it should fix bug 8684 in trunk. I ↵murf1-10/+9
didn't add it to 1.4 yet, because it's not entirely clear to me if this is a bug fix or an enhancement. A lot of files were affected by small changes like ast_variable_new getting an added arg, for the file name the var was defined in; ast_category_new gets added args of filename and lineno; ast_category and ast_variable structures now record file and lineno for each entry; a list of all #include and #execs in a config file (or any of its inclusions are now kept in the ast_config struct; at save time, each entry is put back into its proper file of origin, in order. #include and #exec directives are folded in properly. Headers indicating that the file was generated, are generated also for each included file. Some changes to main/manager.c to take care of file renaming, via the UpdateConfig command. Multiple inclusions of the same file are handled by exploding these into multiple include files, uniquely named. There's probably more, but I can't remember it right now. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@81361 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-17store and destroy implementations for sqlite (closes issue #10446) and odbc ↵tilghman1-0/+212
(closes issue #10447) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@79860 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-16Don't reload a configuration file if nothing has changed.tilghman1-4/+5
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@79747 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-23(closes issue #10271)russell1-84/+72
Reported by: snuffy Patches: doxygen-updates.diff uploaded by snuffy (license 35) Another big batch of doxygen documentation updates git-svn-id: http://svn.digium.com/svn/asterisk/trunk@76559 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-14Add a massive set of changes for converting to use the ast_debug() macro.russell1-3/+3
(issue #9957, patches from mvanbaak, caio1982, critch, and dimas) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@69327 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-08Fix incorrect logic for param count.qwell1-4/+3
Issue 9918. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@68449 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-07Fix a bunch of doxygen errors and document more thingsrussell1-1/+2
(issue #9842, snuffy) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@68339 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-06Issue 9869 - replace malloc and memset with ast_calloc, and other coding ↵tilghman1-42/+42
guidelines changes git-svn-id: http://svn.digium.com/svn/asterisk/trunk@67864 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-01Documentation fixes for res_config_sqlite.qwell1-12/+6
Issue 9854, patch by tzafrir. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@66878 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-30Issue 9477 - Improve menuselect labelstilghman1-1/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@66585 f38db490-d61c-443f-a65b-d21fe96a405b
2007-03-13Merge changes from team/russell/sqlite:russell1-0/+1311
* Add new module, cdr_sqlite3_custom which allows logging custom CDRs into a SQLite3 database. (issue #7149, alerios) * Add new module, res_config_sqlite, which adds realtime database configuration support for SQLite version 2. I decided that this was ok since we didn't have any realtime support for version 3. If someone ports this to version 3, then version 2 support can be removed or marked deprecated. (issue #7790, rbarun_proformatique) * Mark cdr_sqlite as deprecated in favor of cdr_sqlite3_custom. Also, note that there were other modules on the bug tracker that did not make the cut because they provided some duplicated functionality. Those are: * cdr_sqlite3 (issue #6754, moy) * cdr_sqlite3 (issue #8694, bsd) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@58866 f38db490-d61c-443f-a65b-d21fe96a405b