platform/upstream/rpm.git
14 years agoPush most work of ts.addInstall() over to python
Panu Matilainen [Fri, 2 Oct 2009 18:18:27 +0000 (21:18 +0300)]
Push most work of ts.addInstall() over to python
- minimize the stuff done in C: require all arguments in final format
  and report status back with a boolean, handle everything else including
  keylist refcounting hack over to python side

14 years agoOops, missing self in bunch of calls... been too long since writing Python ;)
Panu Matilainen [Fri, 2 Oct 2009 18:14:19 +0000 (21:14 +0300)]
Oops, missing self in bunch of calls... been too long since writing Python ;)

14 years agoPush the rpmtsGetKeys() stuff over to python completely
Panu Matilainen [Fri, 2 Oct 2009 17:35:20 +0000 (20:35 +0300)]
Push the rpmtsGetKeys() stuff over to python completely
- trivially implemented in python by iterating over transaction element
  keys, we dont need no stinking extra librpm APIs for this

14 years agoAdd rpmlog() wrapper to python bindings
Panu Matilainen [Fri, 2 Oct 2009 16:19:31 +0000 (19:19 +0300)]
Add rpmlog() wrapper to python bindings

14 years agoTeach python about RPMDBI_LABEL
Panu Matilainen [Fri, 2 Oct 2009 15:55:16 +0000 (18:55 +0300)]
Teach python about RPMDBI_LABEL

14 years agoSplit rpmbuild dependencies to separate _rpmb module
Panu Matilainen [Fri, 2 Oct 2009 15:31:32 +0000 (18:31 +0300)]
Split rpmbuild dependencies to separate _rpmb module
- installers and the like dont need the pile of poo called librpmbuild for
  anything, avoid dragging it in needlessly
- import _rpmb into rpm namespace if available but dont complain if
  its not there
- arrange ts.parseSpec() compatibility on python side by dynamically
  importing _rpmb if possible

14 years agoMove ts flag & color setting to python side
Panu Matilainen [Fri, 2 Oct 2009 13:36:53 +0000 (16:36 +0300)]
Move ts flag & color setting to python side

14 years agoAdd a dummy python-level transaction set class, use it always
Panu Matilainen [Fri, 2 Oct 2009 13:18:59 +0000 (16:18 +0300)]
Add a dummy python-level transaction set class, use it always
- move the rpm.ts() vs rpm.TransactionSet() compatibility to python
- this will enable doing only the lowest level stuff in C and rest
  in python

14 years agoAdd python method for retrieving header "instance" (db recno) number
Panu Matilainen [Thu, 1 Oct 2009 12:25:01 +0000 (15:25 +0300)]
Add python method for retrieving header "instance" (db recno) number

14 years agoDeprecation tweaks
Panu Matilainen [Thu, 1 Oct 2009 12:12:06 +0000 (15:12 +0300)]
Deprecation tweaks
- use PyErr_WarnEx() for better control and leave the tracking up to python
- use PendingDeprecationWarning for now
- document the replacing functionality in the deprecation messages
- make hdr.sprintf() just an alias to hdr.format() without deprecating,
  at least for now it'd be only a gratuitous incompatible change on python side

14 years agoOops, these are mappings, not dicts...
Panu Matilainen [Thu, 1 Oct 2009 11:55:55 +0000 (14:55 +0300)]
Oops, these are mappings, not dicts...

14 years agoGeneralize python ts flags and colors set/get foo
Panu Matilainen [Thu, 1 Oct 2009 11:27:42 +0000 (14:27 +0300)]
Generalize python ts flags and colors set/get foo
- make flags, vsflags, color, prefcolor (previously not available)
  and probFilter appear as internal attributes of ts objects, each
  with their own setter/getter methods
- make the old custom set/get methods access the internal attributes instead
- keeping them "internal only" leaves room for adding further sanity
  checking and nicer interface on python side while giving direct access
  bits for those who want it
- not deprecating the old get/set methods at least yet...

14 years agoFix couple of recently introduced compiler warnings
Panu Matilainen [Thu, 1 Oct 2009 11:06:41 +0000 (14:06 +0300)]
Fix couple of recently introduced compiler warnings

14 years agoInclude structmembers.h centrally from rpmsystem-py.h
Panu Matilainen [Thu, 1 Oct 2009 10:21:44 +0000 (13:21 +0300)]
Include structmembers.h centrally from rpmsystem-py.h
- pretty much everything might need this...

14 years agoAdd API for setting preferred transaction file color
Panu Matilainen [Thu, 1 Oct 2009 08:37:45 +0000 (11:37 +0300)]
Add API for setting preferred transaction file color
- not strictly needed as it gets its default from a macro but .. shrug

14 years agoMake python ts rootDir appear as a read-only attribute
Panu Matilainen [Thu, 1 Oct 2009 08:21:58 +0000 (11:21 +0300)]
Make python ts rootDir appear as a read-only attribute
- there's no need to change the rootdir after object creation, better
  not permit at all

14 years agoAdd python getter for transaction id
Panu Matilainen [Thu, 1 Oct 2009 08:17:38 +0000 (11:17 +0300)]
Add python getter for transaction id

14 years agoEliminate python ts scriptFd kludgery
Panu Matilainen [Thu, 1 Oct 2009 07:59:53 +0000 (10:59 +0300)]
Eliminate python ts scriptFd kludgery
- make the scriptFd appear as regular attribute by providing a setter
  method for it, permit any file object to be used and allow disabling too
- readonly for now as we dont have rpmfd wrapped yet
- remove now unnecessary custom get/setattr functions

14 years agoDeprecate custom foo.count() methods, support len() instead
Panu Matilainen [Wed, 30 Sep 2009 13:45:46 +0000 (16:45 +0300)]
Deprecate custom foo.count() methods, support len() instead

14 years agoEliminate unused python ts iterator filter stuff
Panu Matilainen [Wed, 30 Sep 2009 13:10:24 +0000 (16:10 +0300)]
Eliminate unused python ts iterator filter stuff
- iterators dont take arguments so there's no convenient way to filter
  while iterating, let python users filter themselves (like they've
  always been doing)

14 years agoTake advantage of headerNextTag() in python hdr.keys()
Panu Matilainen [Wed, 30 Sep 2009 12:04:39 +0000 (15:04 +0300)]
Take advantage of headerNextTag() in python hdr.keys()
- avoids whole lotta unnecessary copying of data, we're only interested
  in tag numbers here
- dont filter out stuff - python consumers can look at i18n data too

14 years agoAdd iterator support to python header objects
Panu Matilainen [Wed, 30 Sep 2009 11:51:33 +0000 (14:51 +0300)]
Add iterator support to python header objects

14 years agoAdd alternative header iterator method
Panu Matilainen [Wed, 30 Sep 2009 11:48:19 +0000 (14:48 +0300)]
Add alternative header iterator method
- we dont always want the actual contents of the tag to be copied
  on iteration, so add an interface that returns the next tag in the
  header
- this lets callers to decide what to do with the tag and how to
  retrieve it

14 years agoAdd some flags to rpmtd creation
Panu Matilainen [Wed, 30 Sep 2009 10:05:24 +0000 (13:05 +0300)]
Add some flags to rpmtd creation
- permit disabling extension retrieval and "raw" (untranslated i18n) tags
- always use HEADERGET_ALLOC for data availability sanity

14 years agoAdd beginnings of rpmtd wrappings to python
Panu Matilainen [Wed, 30 Sep 2009 09:45:07 +0000 (12:45 +0300)]
Add beginnings of rpmtd wrappings to python
- unlike other types, store the C-level td structure directly in the
  python object, this lets us selectively expose some members directly,
  avoids having to deal with rpmtd allocation separately and as leaves
  the reference counting to python as rpmtd's aren't refcounted on C-level

14 years agoTurn hdrGetHeader() into argument parsing converter interface
Panu Matilainen [Wed, 30 Sep 2009 09:11:43 +0000 (12:11 +0300)]
Turn hdrGetHeader() into argument parsing converter interface

14 years agoSanitize getattr behavior of header objects
Panu Matilainen [Wed, 30 Sep 2009 07:33:52 +0000 (10:33 +0300)]
Sanitize getattr behavior of header objects
- when generic getattr fails, only try retrieving header tag as attribute
  if it's a valid tag
- clear any python errors if generic getattr failed
- split generating a python object from header + tag to an internal helper

14 years agoRequire expected type in PyArg_ParseTupleAndKeywords() already
Panu Matilainen [Mon, 28 Sep 2009 15:22:14 +0000 (18:22 +0300)]
Require expected type in PyArg_ParseTupleAndKeywords() already

14 years agoSupport numeric expansion in rpm.expandMacro()
Panu Matilainen [Mon, 28 Sep 2009 14:23:28 +0000 (17:23 +0300)]
Support numeric expansion in rpm.expandMacro()

14 years agoPush rpm.signalsCaught() to python level
Panu Matilainen [Mon, 28 Sep 2009 13:37:14 +0000 (16:37 +0300)]
Push rpm.signalsCaught() to python level
- only implement the bare minimum in C by adding a thin wrapper for
  rpmsqIsCaught(), the rest can easily be done in python

14 years agoImplement rpm.readHeaderFromFD() in python instead of C
Panu Matilainen [Mon, 28 Sep 2009 13:19:22 +0000 (16:19 +0300)]
Implement rpm.readHeaderFromFD() in python instead of C

14 years agoImplement rpm.readHeaderListFromFD() in python instead of C
Panu Matilainen [Mon, 28 Sep 2009 13:07:09 +0000 (16:07 +0300)]
Implement rpm.readHeaderListFromFD() in python instead of C

14 years agoImplement rpmreadHeaderListFromFile() in python instead of C
Panu Matilainen [Mon, 28 Sep 2009 11:50:33 +0000 (14:50 +0300)]
Implement rpmreadHeaderListFromFile() in python instead of C

14 years agoA few cases of Py_RETURN_NONE missed on the first round
Panu Matilainen [Mon, 28 Sep 2009 10:48:19 +0000 (13:48 +0300)]
A few cases of Py_RETURN_NONE missed on the first round

14 years agoArrange rpm.headerLoad() compatibility on python level
Panu Matilainen [Mon, 28 Sep 2009 10:30:28 +0000 (13:30 +0300)]
Arrange rpm.headerLoad() compatibility on python level

14 years agoOSGi dependency generator fixes from Alphonse Van Assche (ticket #101)
Panu Matilainen [Mon, 28 Sep 2009 08:09:32 +0000 (11:09 +0300)]
OSGi dependency generator fixes from Alphonse Van Assche (ticket #101)
- This patch fix some minor bug, remove unused code and increase drastically
  the perf by threading execution of tasks and using zip command instead of
  jar to get meta-data

14 years agoEnable subtyping on the rest of our type-objects
Panu Matilainen [Thu, 24 Sep 2009 10:57:55 +0000 (13:57 +0300)]
Enable subtyping on the rest of our type-objects
- not very useful atm as various places return hard-wired built-in types

14 years agoEliminate all custom tp_free() type methods
Panu Matilainen [Thu, 24 Sep 2009 10:40:44 +0000 (13:40 +0300)]
Eliminate all custom tp_free() type methods
- tp_free()'s purpose is only to free up the memory used by the python
  object structure, cleaning up our own allocations belongs to tp_dealloc()

14 years agoEnable subtyping on rpm.ts class
Panu Matilainen [Thu, 24 Sep 2009 10:19:20 +0000 (13:19 +0300)]
Enable subtyping on rpm.ts class

14 years agoCall generic python setattr if not scriptFd
Panu Matilainen [Thu, 24 Sep 2009 10:05:36 +0000 (13:05 +0300)]
Call generic python setattr if not scriptFd
- yet more preliminaries for subtyping

14 years agotp_setattro() is supposed to return -1 on errors
Panu Matilainen [Thu, 24 Sep 2009 10:04:34 +0000 (13:04 +0300)]
tp_setattro() is supposed to return -1 on errors

14 years agoCall (sub)type tp_free from destructors
Panu Matilainen [Thu, 24 Sep 2009 09:52:32 +0000 (12:52 +0300)]
Call (sub)type tp_free from destructors
- more preliminaries for subtyping
- remove pointless NULL checks

14 years agoMake object allocation type agnostic
Panu Matilainen [Thu, 24 Sep 2009 08:42:17 +0000 (11:42 +0300)]
Make object allocation type agnostic
- pass (sub)type down to wrappers
- call subtype tp_alloc() instead of PyObject_New()
- preliminaries for allowing subtyping

14 years agoRemove unnecessary header type checking
Panu Matilainen [Wed, 23 Sep 2009 14:44:07 +0000 (17:44 +0300)]
Remove unnecessary header type checking
- the type is already validated by PyArg_ParseTupleAndKeywords(),
  no need to doublecheck

14 years agoRemove the broken tp_print method from spec
Panu Matilainen [Wed, 23 Sep 2009 11:41:30 +0000 (14:41 +0300)]
Remove the broken tp_print method from spec

14 years agoDecouple python spec objects from transaction objects
Panu Matilainen [Wed, 23 Sep 2009 11:21:13 +0000 (14:21 +0300)]
Decouple python spec objects from transaction objects
- ts structure is only necessary for hysterically passing back the
  parse result from parseSpec(), hide this in the bindings
- deprecate ts.parseSpec() for later ripping

14 years agoOops, binary data can and should be presented as python strings
Panu Matilainen [Wed, 23 Sep 2009 10:12:43 +0000 (13:12 +0300)]
Oops, binary data can and should be presented as python strings

14 years agoAdd rpmtd to python object converter, change header code to use that
Panu Matilainen [Wed, 23 Sep 2009 09:49:15 +0000 (12:49 +0300)]
Add rpmtd to python object converter, change header code to use that
- vastly simpler than the former goo in hdr_subscribe

14 years agoTurn tagNumFromPyObject() into an object converter interface
Panu Matilainen [Wed, 23 Sep 2009 09:28:47 +0000 (12:28 +0300)]
Turn tagNumFromPyObject() into an object converter interface
- permits direct validation and conversion from arg parsing

14 years agoTurn rpmFdFromPyObject() into an object converter interface
Panu Matilainen [Wed, 23 Sep 2009 09:05:02 +0000 (12:05 +0300)]
Turn rpmFdFromPyObject() into an object converter interface
- permits direct validation and conversion from arg parsing

14 years agoPermit any file object in rpm.readHeaderListFromFD()
Panu Matilainen [Wed, 23 Sep 2009 08:51:55 +0000 (11:51 +0300)]
Permit any file object in rpm.readHeaderListFromFD()

14 years agoPermit file objects in python header constructor
Panu Matilainen [Wed, 23 Sep 2009 08:42:59 +0000 (11:42 +0300)]
Permit file objects in python header constructor

14 years agoAdd write() method to python headers
Panu Matilainen [Wed, 23 Sep 2009 08:41:20 +0000 (11:41 +0300)]
Add write() method to python headers

14 years agoAccept any file object in ts.hdrFromFdno()
Panu Matilainen [Wed, 23 Sep 2009 08:10:38 +0000 (11:10 +0300)]
Accept any file object in ts.hdrFromFdno()

14 years agoAdd helper to convert python file objects to rpmio FD_t type
Panu Matilainen [Wed, 23 Sep 2009 08:09:19 +0000 (11:09 +0300)]
Add helper to convert python file objects to rpmio FD_t type

14 years agoAdd te.NEVRA() method, adjust docs
Panu Matilainen [Wed, 23 Sep 2009 07:49:47 +0000 (10:49 +0300)]
Add te.NEVRA() method, adjust docs

14 years agoRemove tp_print methods from all rpm-python objects
Panu Matilainen [Wed, 23 Sep 2009 07:44:41 +0000 (10:44 +0300)]
Remove tp_print methods from all rpm-python objects
- these violate the intended use of tp_print, python docs state
  "A type should never implement tp_print in a way that produces
  different output than tp_repr or tp_str would."

14 years agoLose the debug junk from python bindings
Panu Matilainen [Wed, 23 Sep 2009 07:39:40 +0000 (10:39 +0300)]
Lose the debug junk from python bindings

14 years agoAdd hdr.format(), deprecate hdr.sprintf()
Panu Matilainen [Wed, 23 Sep 2009 07:31:46 +0000 (10:31 +0300)]
Add hdr.format(), deprecate hdr.sprintf()
- sprintf() is a C'ism and format() is closer to current librpm anyway

14 years agoMake fiFromHeader() static inside header-py, deprecate
Panu Matilainen [Wed, 23 Sep 2009 07:19:46 +0000 (10:19 +0300)]
Make fiFromHeader() static inside header-py, deprecate

14 years agoDeprecate rpm.headerLoad()
Panu Matilainen [Wed, 23 Sep 2009 07:11:45 +0000 (10:11 +0300)]
Deprecate rpm.headerLoad()
- this is not needed now, just call rpm.hdr(<blob) to load

14 years agoDeprecate header filelist munging methods
Panu Matilainen [Wed, 23 Sep 2009 06:56:08 +0000 (09:56 +0300)]
Deprecate header filelist munging methods
- hdr.convert() is the generic way, the old stuff is not needed anymore
- macro to issue warnings just once

14 years agoEliminate unnecessary function
Panu Matilainen [Wed, 23 Sep 2009 06:27:47 +0000 (09:27 +0300)]
Eliminate unnecessary function

14 years agoPermit headerConvert() from python
Panu Matilainen [Wed, 23 Sep 2009 06:24:23 +0000 (09:24 +0300)]
Permit headerConvert() from python

14 years agoAdd has_key() method to header object
Panu Matilainen [Wed, 23 Sep 2009 06:03:25 +0000 (09:03 +0300)]
Add has_key() method to header object

14 years agoAdd support for creating new header objects
Panu Matilainen [Wed, 23 Sep 2009 05:51:12 +0000 (08:51 +0300)]
Add support for creating new header objects
- without arguments, rpm.hdr() creates an empty header
- with another header as argument, make a copy
- string argument is considered an unloaded header blob and copy-loaded

14 years agoRpm's allocators dont return on OOM, remove unnecessary check
Panu Matilainen [Wed, 23 Sep 2009 05:41:03 +0000 (08:41 +0300)]
Rpm's allocators dont return on OOM, remove unnecessary check

14 years agoAdd type checking macros for all rpm python type objects
Panu Matilainen [Tue, 22 Sep 2009 21:06:13 +0000 (00:06 +0300)]
Add type checking macros for all rpm python type objects

14 years agoRename python system.h for disambiguation
Panu Matilainen [Tue, 22 Sep 2009 20:02:47 +0000 (23:02 +0300)]
Rename python system.h for disambiguation

14 years agoLose the empty doxygen markers
Panu Matilainen [Tue, 22 Sep 2009 19:42:06 +0000 (22:42 +0300)]
Lose the empty doxygen markers
- nothing wrong with comments but empty comment placeholders
  are not exactly useful

14 years agoPut some consistency to python object creation
Panu Matilainen [Tue, 22 Sep 2009 18:53:21 +0000 (21:53 +0300)]
Put some consistency to python object creation
- all type object creation goes through foo_Wrap() which handle OOM
  and all type specific initialization

14 years agoMake all python object creation wrappers return PyObject pointers
Panu Matilainen [Tue, 22 Sep 2009 18:24:55 +0000 (21:24 +0300)]
Make all python object creation wrappers return PyObject pointers
- this way the only place where casts are needed are in the wrapper itself

14 years agoDont leak memory on rpm.ds iteration
Panu Matilainen [Tue, 22 Sep 2009 18:01:01 +0000 (21:01 +0300)]
Dont leak memory on rpm.ds iteration

14 years agoLose unnecessary next() methods
Panu Matilainen [Tue, 22 Sep 2009 17:50:41 +0000 (20:50 +0300)]
Lose unnecessary next() methods
- python adds next() methods for objects supporting iterators

14 years agoAll rpm-python iterators are self-iterators, just use PyObject_SelfIter
Panu Matilainen [Tue, 22 Sep 2009 17:20:07 +0000 (20:20 +0300)]
All rpm-python iterators are self-iterators, just use PyObject_SelfIter

14 years agoDont leak memory from rpm.dsSingle()
Panu Matilainen [Tue, 22 Sep 2009 16:55:34 +0000 (19:55 +0300)]
Dont leak memory from rpm.dsSingle()

14 years agoSimplify fiFromHeader()
Panu Matilainen [Tue, 22 Sep 2009 16:44:59 +0000 (19:44 +0300)]
Simplify fiFromHeader()
- just call the fi object, no need to manually redo all this stuff

14 years agoSimplify dsFromHeader()
Panu Matilainen [Tue, 22 Sep 2009 16:42:53 +0000 (19:42 +0300)]
Simplify dsFromHeader()
- just call the ds object, no need to manually redo all this stuff

14 years agoSanitize python object -> tag number exception handling
Panu Matilainen [Tue, 22 Sep 2009 16:19:02 +0000 (19:19 +0300)]
Sanitize python object -> tag number exception handling
- raise exception in tagNumFromPyObject(), not in 12 different callers
- check against RPMTAG_NOT_FOUND consistently instead of -1 and whatnot
- unknown tags are value, not key or type errors

14 years agoMove allocations out of rpmps object init method
Panu Matilainen [Tue, 22 Sep 2009 15:55:09 +0000 (18:55 +0300)]
Move allocations out of rpmps object init method
- tp_init can be called several times, allocating from there leaks memory
- tp_init gets called automatically on object creation, dont call manually
- nothing to initialize for rpmps...

14 years agoMove allocations out of rpmds object init method
Panu Matilainen [Tue, 22 Sep 2009 15:53:15 +0000 (18:53 +0300)]
Move allocations out of rpmds object init method
- tp_init can be called several times, allocating from there leaks memory
- tp_init gets called automatically on object creation, dont call manually

14 years agoMove allocations out of rpmfi object init method
Panu Matilainen [Tue, 22 Sep 2009 15:50:32 +0000 (18:50 +0300)]
Move allocations out of rpmfi object init method
- tp_init can be called several times, allocating from there leaks memory
- tp_init gets called automatically on object creation, dont call manually

14 years agoRemove useless rpmts python initialization
Panu Matilainen [Tue, 22 Sep 2009 15:22:50 +0000 (18:22 +0300)]
Remove useless rpmts python initialization

14 years agoRealize the remaining bits of direct rpmdb interface are dead too
Panu Matilainen [Tue, 22 Sep 2009 15:17:49 +0000 (18:17 +0300)]
Realize the remaining bits of direct rpmdb interface are dead too
- the code hasn't been enabled in a long long time despite being built...

14 years agoUse Py_RETURN_NONE macro for returning None everywhere
Panu Matilainen [Tue, 22 Sep 2009 14:49:53 +0000 (17:49 +0300)]
Use Py_RETURN_NONE macro for returning None everywhere

14 years agoEliminate unnecessary custom object allocation functions
Panu Matilainen [Tue, 22 Sep 2009 14:33:07 +0000 (17:33 +0300)]
Eliminate unnecessary custom object allocation functions
- these are just calling python defaults, no point at all...

14 years agoUse generic python get/set attribute functions directly where appropriate
Panu Matilainen [Tue, 22 Sep 2009 14:27:44 +0000 (17:27 +0300)]
Use generic python get/set attribute functions directly where appropriate
- no point in wrapping all this stuff in our own functions

14 years agoPython initialization spring clean
Panu Matilainen [Tue, 22 Sep 2009 14:12:22 +0000 (17:12 +0300)]
Python initialization spring clean
- split rpmtag enum additions to seprate function
- PyModule_AddIntConstant() does exactly what we need for the rest

14 years agoMake the python object structures opaque
Panu Matilainen [Tue, 22 Sep 2009 13:47:07 +0000 (16:47 +0300)]
Make the python object structures opaque

14 years agoLose the utterly broken rpmio FD_t wrappers
Panu Matilainen [Tue, 22 Sep 2009 13:39:39 +0000 (16:39 +0300)]
Lose the utterly broken rpmio FD_t wrappers

14 years agoLose the useless python debug stuff
Panu Matilainen [Tue, 22 Sep 2009 13:36:48 +0000 (16:36 +0300)]
Lose the useless python debug stuff

14 years agoWe dont support ancient python versions...
Panu Matilainen [Tue, 22 Sep 2009 13:28:58 +0000 (16:28 +0300)]
We dont support ancient python versions...

14 years agoKick out mummified rpmdb python interface remnants
Panu Matilainen [Tue, 22 Sep 2009 13:24:32 +0000 (16:24 +0300)]
Kick out mummified rpmdb python interface remnants

14 years agoMissing <string.h> include
Panu Matilainen [Tue, 22 Sep 2009 13:02:39 +0000 (16:02 +0300)]
Missing <string.h> include

14 years agoClean up + fix bad recno erasure in python ts.addErase()
Panu Matilainen [Tue, 22 Sep 2009 12:36:11 +0000 (15:36 +0300)]
Clean up + fix bad recno erasure in python ts.addErase()
- now that we can loop over RPMDBI_PACKAGES matches, the code can
  be simplified quite a bit
- walk through the iterator always to get a reliable installed status,
  previously ts.addErase() with bad record number wouldn't raise exception

14 years agoRemove no longer necessary RPMDBI_PACKAGES special casing
Panu Matilainen [Tue, 22 Sep 2009 11:53:56 +0000 (14:53 +0300)]
Remove no longer necessary RPMDBI_PACKAGES special casing

14 years agoFix endless loop on RPMDBI_PACKAGES iteration when offset specified
Panu Matilainen [Tue, 22 Sep 2009 11:52:57 +0000 (14:52 +0300)]
Fix endless loop on RPMDBI_PACKAGES iteration when offset specified

14 years agoUnbreak --tid and --querybynumber
Panu Matilainen [Tue, 22 Sep 2009 09:32:02 +0000 (12:32 +0300)]
Unbreak --tid and --querybynumber
- broken ages ago somewhere between 4.4.x and 4.6.x by typing changes
  presumably
- C99 strtoul() can figure the base on its own, remove unnecessary work

14 years agoDB_INCOMPLETE was removed in BDB 4.1 and we dont support older versions
Panu Matilainen [Tue, 22 Sep 2009 07:21:47 +0000 (10:21 +0300)]
DB_INCOMPLETE was removed in BDB 4.1 and we dont support older versions

14 years agoRemove ancient, unused code to filter duplicates on rpmdb rebuild
Panu Matilainen [Tue, 22 Sep 2009 06:26:39 +0000 (09:26 +0300)]
Remove ancient, unused code to filter duplicates on rpmdb rebuild
- enabling this as-is would be murderous to multilib systems
- getting duplicates in the db would be a bug elsewhere