summaryrefslogtreecommitdiff
path: root/lib/rpmps.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix couple of incorrect sizeof() usesPanu Matilainen2011-03-171-1/+1
|
* Eliminate all fooUnlink() functions out of the APIPanu Matilainen2010-09-131-1/+1
| | | | | | | | - These are internal helpers only, all refcount users need to use fooFree() or similar for correct operation. Add fwd declarations where necessary to avoid moving code around unnecessarily. - We could add these back later as aliases to fooFree() but for now, just get them out of the way.
* Plug dumb memleak in rpmpsMerge()Panu Matilainen2010-05-071-0/+1
|
* Eliminate unused "known problems" based filtering from rpmtsRun()Rakesh Pandit2010-04-211-37/+0
| | | | | | | | - This mechanism has never been used by anything at all, which suggests its not a particularly useful feature - Removing unused rpmpsTrim() from rpmps - Marking okProbs parameter of rpmtsRun() function as unused to avoid unnecessary breakage
* Filter out duplicate problems when adding to element problem setsPanu Matilainen2010-03-261-30/+10
| | | | | | | | | | | | | - Problems associated with a transaction element are necessarily unique to that element, so when filtered there we don't have to worry about skipping dupes elsewhere like in merged sets. This can actually lead to apparent duplicates in the current problem report output (eg in cases where multiple packages provide the same dependency which would be removed, like multilib packages), but this is only an artifact of they way the problems are currently printed out. - While this is still a dumb linear search, it can be several seconds faster than the previous filtering in rpmpsPrint(), which is now just a dumb convenience function.
* Eliminate rpmpsAppend() from the APIPanu Matilainen2010-03-261-12/+0
| | | | | | | | | - This was only a convenience function that shouldn't really have been exported to begin with, and is not necessary at all - bury it inside rpmte.c for now to hide lazy problem set allocation - In the other news of the day... According to git, this happens to be the 10000th commit to the master branch of this codebase. Happy anniversary to rpm :P
* Push problem creation argument sanitation to the level belowPanu Matilainen2010-03-261-4/+3
| | | | | | | - rpmpsAppend() and rpmProblemCreate() have no use for fn/dn either, its just stored in one string internally - this is kinda unnecessary API break but these aren't used outside rpm so it doesn't make much difference
* Add a simple and dumb rpmpsMerge() function to merge two problem setsPanu Matilainen2010-03-261-0/+16
|
* Add a saner rpmps iteration interfacePanu Matilainen2010-03-261-8/+13
| | | | | | | - simply return the actual problem objects from the iterator instead of "index" which is not usable for anything outside rpmps.c - implement rpmpsNexIterator() on top of the new rpmpsiNext() as backwards compatibility for now
* Split rpm problem type + its "methods" to separate source + headerPanu Matilainen2010-03-251-208/+0
| | | | | - rpmps is just something that stores rpm problems, problems themselves are individual and opaque "objects", deserving their own module
* Add public function for testing problem equalityPanu Matilainen2010-03-251-20/+22
| | | | | | - turn around sameProblem() return, pay more attention to details and make it public - use it in rpmpsTrim() too
* Lose unused ignoreProblem from rpmProblem structPanu Matilainen2010-03-251-10/+0
| | | | | | - this is an artifact from rpm 4.4.x-times, and even back then nothing used it, the only api to set it was in python bindings and.. eww - also killing this makes rpmpsTrim() do something semi-useful again
* Minor cleanup to rpmpsGetProblem()Panu Matilainen2010-03-251-3/+3
| | | | - avoid dumb pointer fiddles, ps->probs is just a bleeping array
* Minor cleanup to rpmpsAppendProblem()Panu Matilainen2010-03-251-4/+2
| | | | | - dont bother adding NULL problems - avoid dumb pointer fiddles, ps->probs is just a bleeping array
* Minor cleanup to rpmpsFreeIterator()Panu Matilainen2010-03-251-2/+1
|
* Dont bother allocating iterator if there's no data to iteratePanu Matilainen2010-03-251-1/+1
|
* Lose the useless rpmps refcounting debug junkPanu Matilainen2010-03-221-8/+6
| | | | | - get the debug messages out of API, this is what should've been in commit dbdbe8010cd944f026a5a4e5d071eb31d29d81c4
* Add a new problem type for obsoletesPanu Matilainen2010-03-181-0/+5
|
* Include <stdlib.h> as necessary instead of system.hPanu Matilainen2010-01-051-0/+1
| | | | - also loose the related ancient compatibility goo
* Replace equal/not equal uses of str[n]cmp() with rstreq[n] in main ts codePanu Matilainen2009-08-311-4/+4
|
* sameProblem() return value is illogical, reverse itPanu Matilainen2009-08-311-7/+7
|
* Kill off lclint remnants everywherePanu Matilainen2009-07-231-1/+0
| | | | - remove ancient and likely irrelevant LCL comments and bogus NULL checks
* Make rpmpsUnlink() behave the other fooUnlink() functionsPanu Matilainen2009-07-091-10/+10
| | | | | | - pretty much everything else in rpm returns NULL from unreference functions, make be more consistent here... - also tolerate NULL in both reference and unreference
* Add reference counting to rpmProblemsPanu Matilainen2009-07-091-3/+26
|
* Return NULL instead of blowing up on invalid rpmpsGetProblem()Panu Matilainen2009-01-221-1/+1
| | | | - thanks to Pixel for spotting
* Use PRIu64 for 64bit value formatting instead of castingPanu Matilainen2008-10-141-3/+5
|
* Fix type in format string to avoid segfault (rhbz#460146)Jindrich Novy2008-08-261-1/+1
|
* Make rpmps generic number field 64bit, rename getter methodPanu Matilainen2008-06-111-16/+16
| | | | | | | | | | - rename the parameters + internal use to more generic "number" - rename ugly and dumb rpmProblemGetLong() to rpmProblemGetDiskNeed() and return rpm_loff_t - the number field is used for some other purposes too (whether dep problem is for installed package), work around this for now by just defining rpmProblemGetDiskNeed() result value as undefined on non-disk related problems ;)
* Use rasprintf() in rpmps to properly fix mdvbz#31680Panu Matilainen2008-03-181-18/+14
|
* Stop insecurely covering up for lack of snprintf and vsnprintfPanu Matilainen2008-03-071-19/+0
| | | | | | | - we require C99 anyway - snprintf is used unconditionally all around the tree - if absolutely needed for portability, having insecure wrappers littered over the source is not the best way
* Remove bunch of unnecessary rpmlib.h includesPanu Matilainen2008-01-301-2/+0
| | | | - replace with rpmtypes.h where needed
* Bandaid patch for truncated error message in russian (mdvbz#31680)Panu Matilainen2008-01-251-1/+1
| | | | | Just up the stupid static reservation "high enuff" for now. asprintf() would be nice here but it's not at all portable, revisit later.
* Remove bogus const from rpmProblemString() return typePanu Matilainen2007-12-151-1/+1
| | | | | - its malloced so it needs to be freed - fix all users to actually free
* Another bunch of bogus const removalsPanu Matilainen2007-12-141-1/+1
|
* Oops, rpmpsi index needs to be signed typePanu Matilainen2007-12-141-2/+2
|
* Switch to <rpm/foo.h> style for public headersPanu Matilainen2007-12-081-2/+2
| | | | - adjust include paths accordingly
* Eliminate debug junk from the APIPanu Matilainen2007-12-041-10/+8
| | | | | - add some helper macros to accomplish the same, easy to enable / disable as needed
* Use #include <x.h> syntax to include public headers.Ralf Corsépius2007-11-231-2/+2
|
* Remove bunch of unnecessary misc.h includes, document othersPanu Matilainen2007-11-071-1/+0
|
* Include "rpmlib.h" instead of <rpmlib.h>.Ralf Corsépius2007-10-281-1/+1
|
* Rename rpmpsProblem() -> rpmpsGetProblem() to make purpose clearerPanu Matilainen2007-10-191-4/+4
|
* Make rpmProblem standalone "object"Panu Matilainen2007-10-191-39/+66
| | | | | | | | | - problem set contains array of pointers to problems, not problems themselves - add functions for creating and destroying problems - use iterators for freeing the problems in rpmpsFree() - new rpmpsAppendProblem() API for appending existing problem item to problem set - implement rpmpsAppend using the new methods
* Eliminate rpmps and rpmProblem structure details from the APIPanu Matilainen2007-10-191-0/+26
|
* Add methods for accessing rpmProblem dataPanu Matilainen2007-10-191-0/+30
|
* Use iterators for rpmpsPrint()Panu Matilainen2007-10-181-6/+9
|
* Add API for iterating over rpmps problemsPanu Matilainen2007-10-181-0/+44
|
* Remove unimplemented, unused RPMPROB_BADPRETRANSPanu Matilainen2007-10-161-5/+0
| | | | - leftover from pretrans syscall hack before %pretrans script days
* Remove splint tags.Ralf Corsépius2007-09-111-27/+5
|
* - spelling corrections (#112728).jbj2003-12-301-1/+1
| | | | | | CVS patchset: 7047 CVS date: 2003/12/30 13:14:49
* - add --with-efence to configure, check install/upgrade with efence.jbj2002-08-191-4/+4
| | | | | | | | | | | | | | | | - beecrypt: short hex string conversion overflows target buffer. - mark "successors only" packages in transaction. - reap scriptlets with SIGCHLD handler. - rename PSM_t to rpmpsm, add methods and refcounts to manage. - remove %%configure/%%makeinstall from arch-os/macros, default is OK. - don't export MALLOC_CHECK_ to scriptlets. - squeaky clean memory leak checking. - always malloc rpmfi structure, refcounts are correct in rpmtsRun(). - skip redundant /sbin/ldconfig scripts on upgrade (if possible). CVS patchset: 5645 CVS date: 2002/08/19 22:27:44