summaryrefslogtreecommitdiff
path: root/lib/backend
AgeCommit message (Collapse)AuthorFilesLines
2010-03-19Lose unused temporary/pseudo rpmdbi tagsPanu Matilainen1-1/+0
- we haven't had any temporary dbis since rpm 4.8.0 where Depends got axed, the rest were just nonexistent fluff anyway
2010-01-05Move <errno.h> include out of system.h to the places that need itPanu Matilainen1-0/+1
2010-01-05Unconditionally include <sys/wait.h> where neededPanu Matilainen1-0/+1
- no point conditionalizing what we cant live without
2009-12-07Removed obsolete "db3" entry in dbi_config_defaultFlorian Festi1-1/+1
2009-12-07Remove support for sqlite based rpm databaseFlorian Festi3-1438/+137
Also remove abstraction layer between rpmdb.h and the back end in lib/backend/
2009-09-22DB_INCOMPLETE was removed in BDB 4.1 and we dont support older versionsPanu Matilainen1-5/+3
2009-09-21Move rpmdb home creation from backends to one level higherPanu Matilainen2-12/+2
- this is a common operation for any backends, avoid duplication - only try to create it once instead of every index open, and if it doesn't exist and cant be created, error out instead of trying to continue in vain
2009-09-21Add an internal API for getting rpmdb home wrt chroot state, use itPanu Matilainen1-18/+5
2009-09-21Remove pointless per-index api versionPanu Matilainen1-3/+3
2009-09-21DB config stuff not needed outside dbconfig.c, make them staticPanu Matilainen1-5/+4
- additionally make the popt struct const since it can...
2009-09-21BDB is not optional at least currently, remove useless ifdefsPanu Matilainen1-6/+0
2009-09-21Remove useless no-op "teardown" and "usecursors" config bitsPanu Matilainen1-9/+1
2009-09-21Remove BDB RPC "support"Panu Matilainen2-69/+20
- it's insecure, used by nobody (its been rather broken for a long time) and all, but BDB 4.8.x removed RPC support from upstream so we cant very well support in the future even if we wanted to
2009-09-21Remove XA "support" from the backendPanu Matilainen1-3/+0
- it's removed from BDB 4.8.x and this has hardly ever done anything anyway
2009-09-21Remove unused db/dbenv methods "documentary" from the sourcePanu Matilainen1-38/+0
2009-09-21Use db3Free() for on sqlite backend close tooPanu Matilainen1-6/+1
2009-09-21Always populate dbi->dbi_file on db3New()Panu Matilainen3-34/+15
- Only the actual db->open() wants NULL for temporary databases, everywhere else we want the tag name. Handle the temporary case where it counts instead of complicating things everywhere for the one special case.
2009-09-21Mop up leftover root/home foobarPanu Matilainen2-32/+7
2009-09-21Per-dbi root and home dont make sense, always use rpmdb pathsPanu Matilainen3-18/+11
2009-09-18Sigh.. when not using environment, absolute paths are requiredPanu Matilainen1-1/+7
2009-09-17Always open database files relative to database homePanu Matilainen1-8/+1
- This allows the db to move freely wherever (such as across chroots, RhBug:507309 and pile of related issues) .. and is even recommended by BDB documentation. Well duh.
2009-09-17Have BDB use our allocation routines now that we canPanu Matilainen1-5/+2
- rfree() prototype doesn't match free() but it doesn't matter in this case as it's just a convencience wrapper with no extra functionality and setting NULL is ok according to BDB docs - db->set_alloc() can't be used if environment is used, fix the condition
2009-09-17Eliminate unnecessary variablePanu Matilainen1-7/+4
2009-09-16Remove db environment on close on chrooted operationsPanu Matilainen1-1/+2
- As we open the db from outside the chroot, the environment ends up containing paths that are not valid once we enter the chroot causing dumb issues like RhBug:513699 and RhBug:507309. - We'd be better off removing the environment always after access but limiting to chroots for now as the rpmdb open/close path is full of races when environment is not present. Chroots are somewhat special environemnts anyway and typically not concurrently accessed so it's less of an issue there. - While this still has all sorts of issues, it at least leaves the rpmdb in chroot in a functional state after initial install.
2009-09-16There's a function to test string equivalence...Panu Matilainen2-5/+5
2009-09-16Throw out useless db statistics structsPanu Matilainen1-47/+0
- besides being completely unused, these structs are defined by BDB public headers, no need to mirror them in rpm
2009-09-16Throw out pile of unused "stuff" from 2002Panu Matilainen1-71/+0
2009-09-16One complicated way to write xstrdup() .. pffPanu Matilainen1-10/+3
- sqlite backend uses dbi subfile for table name, leave it alone although it is the same as the file name... - allocate + free both file and table name separately
2009-09-16Eliminate long since unused db subfile from bdb codePanu Matilainen1-24/+2
2009-09-16Remove unnecessary arguments to db init and finiPanu Matilainen1-20/+9
- bdb environments are per db_home, not per file so dbfile etc dont make sense here
2009-08-31Replace equal/not equal uses of str[n]cmp() with rstreq[n] in backend codePanu Matilainen2-6/+6
2009-01-19Use temporary table for Depends DB in sqlite too (Olivier Thauvin)Panu Matilainen1-2/+4
2009-01-14Actually check for dbenv->failchk() exit codePanu Matilainen1-0/+3
- failchk() can't resolve all cases, we shouldn't try to continue if it fails
2009-01-09Remove unused database intex functions: dbiCdup, dbiAssociate, dbiPget, dbiJoinFlorian Festi2-133/+2
and their implementations in the backends
2008-11-04Use more portable file access mode tests (ticket #5)Panu Matilainen1-5/+5
- don't make assumptions about how O_RDWR and friends are defined, use the portable way of masking flags with O_ACCMODE and explicit comparison against the mode we're interested in
2008-10-14Avoid overflow on memcpy()Panu Matilainen1-2/+2
2008-10-14Need to mask the return type from rpmTagGetType() return valuePanu Matilainen1-2/+2
2008-10-14Error out on unknown data types in sqlite backend tooPanu Matilainen1-2/+7
2008-10-09Get db vectors out of exported ABIPanu Matilainen3-0/+3
2008-06-06Fix typo in sqlite backend preventing it from buildingPanu Matilainen1-1/+1
2008-06-06Teach sqlite backend 64bit handlingJindrich Novy1-13/+31
2008-05-21Include rpmtypes.h first instead of rpmtag.h everywherePanu Matilainen3-3/+3
2008-05-12Fixup paths and Makefiles for rpmdb/ eliminationPanu Matilainen3-6/+6
2008-05-12Start (re-)joining librpmdb and librpmPanu Matilainen3-0/+3043
- the split is largely arbitrary and mostly just causes, well, arbitrary issues and limitations - just move content from rpmdb/ to lib/ for now