rpm 5.3.7
|
Go to the source code of this file.
Functions | |
void | argvPrint (const char *msg, ARGV_t argv, FILE *fp) |
Print argv array elements. | |
ARGI_t | argiFree (ARGI_t argi) |
Destroy an argi array. | |
ARGV_t | argvFree (ARGV_t argv) |
Destroy an argv array. | |
int | argiCount (ARGI_t argi) |
Return no. | |
ARGint_t | argiData (ARGI_t argi) |
Return data from argi array. | |
int | argvCount (const ARGV_t argv) |
Return no. | |
ARGV_t | argvData (ARGV_t argv) |
Return data from argv array. | |
int | argiCmp (ARGint_t *a, ARGint_t *b) |
Compare argi elements (qsort/bsearch). | |
int | argvCmp (ARGstr_t *a, ARGstr_t *b) |
Compare argv elements using strcmp (qsort/bsearch). | |
int | argvStrcasecmp (ARGstr_t *a, ARGstr_t *b) |
Compare argv elements using strcasecmp (qsort/bsearch). | |
int | argiSort (ARGI_t argi, int(*compar)(ARGint_t *, ARGint_t *)) |
Sort an argi array. | |
int | argvSort (ARGV_t argv, int(*compar)(ARGstr_t *, ARGstr_t *)) |
Sort an argv array. | |
ARGV_t | argvSearch (ARGV_t argv, ARGstr_t val, int(*compar)(ARGstr_t *, ARGstr_t *)) |
Find an element in an argv array. | |
int | argiAdd (ARGI_t *argip, int ix, int val) |
Add an int to an argi array. | |
int | argvAdd (ARGV_t *argvp, ARGstr_t val) |
Add a string to an argv array. | |
int | argvAppend (ARGV_t *argvp, ARGV_t av) |
Append one argv array to another. | |
int | argvSplit (ARGV_t *argvp, const char *str, const char *seps) |
Split a string into an argv array. | |
char * | argvJoin (ARGV_t argv, char sep) |
Concatenate an argv array into a string. | |
int | argvFgets (ARGV_t *argvp, void *fd) |
Read lines into an argv array. |
Definition in file argv.c.
int argiAdd | ( | ARGI_t * | argip, |
int | ix, | ||
int | val | ||
) |
Add an int to an argi array.
*argip | argi array |
ix | argi array index (or -1 to append) |
val | int arg to add |
Definition at line 173 of file argv.c.
References ARGI_s::nvals, ARGI_s::vals, xcalloc(), and xrealloc().
Referenced by mtreeArgCallback(), nwlookupTag(), rpmdcParseCoreutils(), rpmdcParseZeroInstall(), rpmfcApply(), rpmfcClassify(), runImmedTriggers(), runTriggersLoop(), set(), and wnlookupTag().
Compare argi elements (qsort/bsearch).
a | 1st instance address |
b | 2nd instance address |
Definition at line 82 of file argv.c.
Referenced by argiSort().
int argiCount | ( | const ARGI_t | argi | ) |
Return no.
of elements in argi array.
argi | argi array |
Definition at line 50 of file argv.c.
References ARGI_s::nvals.
Referenced by argiSort(), main(), nwlookupTag(), rpmfcApply(), rpmfcGenerateDepends(), runImmedTriggers(), runTriggersLoop(), and wnlookupTag().
Return data from argi array.
argi | argi array |
Definition at line 58 of file argv.c.
References ARGI_s::nvals, and ARGI_s::vals.
Referenced by argiSort(), nwlookupTag(), rpmfcGenerateDepends(), runImmedTriggers(), runTriggersLoop(), and wnlookupTag().
Destroy an argi array.
argi | argi array |
Definition at line 29 of file argv.c.
References _free(), ARGI_s::nvals, and ARGI_s::vals.
Referenced by main(), needswhatTag(), rpmfcFini(), runImmedTriggers(), runTriggersLoop(), and whatneedsTag().
Sort an argi array.
argi | argi array |
compar | strcmp-like comparison function, or NULL for argiCmp() |
Definition at line 120 of file argv.c.
References argiCmp(), argiCount(), and argiData().
Referenced by runImmedTriggers(), and runTriggersLoop().
Add a string to an argv array.
*argvp | argv array |
val | string arg to append |
Definition at line 194 of file argv.c.
References argvCount(), xrealloc(), and xstrdup().
Referenced by argvFgets(), dbiMireKeys(), main(), missingokTag(), needswhatTag(), nwlookupTag(), parseFormat(), rpmcliInstall(), rpmdbTriggerGlobs(), rpmdcParseCoreutils(), rpmdcParseZeroInstall(), rpmfcClassify(), rpmfcSaveArg(), rpmfiOpendir(), rpmioParse(), rpmperlNew(), rpmrepoDoPkgMetadata(), rpmrepoGetFileList(), rpmrepoInitPopt(), rpmteChain(), runImmedTriggers(), set(), unsatisfiedDepend(), whatneedsTag(), and wnlookupTag().
Append one argv array to another.
*argvp | argv array |
av | argv array to append (NULL does nothing) |
Definition at line 211 of file argv.c.
References argvCount(), xrealloc(), and xstrdup().
Referenced by dbiMireKeys(), main(), rpmcliInstallElementPath(), rpmfcExec(), rpmgiGlobArgv(), rpmperlNew(), rpmrubyNew(), rpmsqlNew(), and rpmvtNew().
Compare argv elements using strcmp (qsort/bsearch).
a | 1st instance address |
b | 2nd instance address |
Definition at line 90 of file argv.c.
Referenced by argvSearch(), and argvSort().
int argvCount | ( | ARGV_t | argv | ) |
Return no.
of elements in argv array.
argv | argv array |
Definition at line 66 of file argv.c.
Referenced by _rpmsqlDebugDump(), argvAdd(), argvAppend(), argvSearch(), argvSort(), findTag(), getMachineInfo(), hSaveBlinks(), hSaveFlinks(), main(), needswhatTag(), packageSources(), rpmcliInstallElementPath(), rpmdbTriggerGlobs(), rpmfcApply(), rpmfcClassify(), rpmfcExpandAppend(), rpmfcGenerateDepends(), rpmfcHelper(), rpmperlNew(), rpmpythonNew(), rpmrepoDoPkgMetadata(), rpmrepoInitPopt(), rpmrubyNew(), rpmsqlArgv(), rpmsqlNew(), rpmsquirrelNew(), rpmtclNew(), rpmtsOpenSDB(), rpmtsSanityCheck(), rpmvtNew(), rpnFormat(), strsubFormat(), and whatneedsTag().
Return data from argv array.
argv | argv array |
Definition at line 75 of file argv.c.
Referenced by hSaveBlinks(), hSaveFlinks(), and rpmfcGenerateDepends().
int argvFgets | ( | ARGV_t * | argvp, |
void * | fd | ||
) |
Destroy an argv array.
argv | argv array |
Definition at line 39 of file argv.c.
References _free().
Referenced by argvFgets(), argvSplit(), dbiMireKeys(), delTE(), formatValue(), freeFormat(), getMachineInfo(), main(), missingokTag(), needswhatTag(), packageSources(), parsePrep(), processPackageFiles(), processSourceFiles(), rpmcliInstall(), rpmcliInstallElementPath(), rpmdbTriggerGlobs(), rpmdbURIPath(), rpmdsNew(), rpmfcClassify(), rpmfcExec(), rpmfcFini(), rpmfcGenerateDepends(), rpmfcHelper(), rpmfiNew(), rpmfiOpendir(), rpmgiFini(), rpmgiGlobArgv(), rpmioParse(), rpmioPFree(), rpmperlNew(), rpmrepoDoPkgMetadata(), rpmrepoFini(), rpmrubyFini(), rpmsqlFini(), rpmtsFini(), rpmtsOpenSDB(), rpmtsSanityCheck(), rpmtsSkipFiles(), rpmvtFini(), runImmedTriggers(), runTriggers(), tagClean(), tagLoadATags(), unsatisfiedDepend(), and whatneedsTag().
char* argvJoin | ( | ARGV_t | argv, |
char | sep | ||
) |
Concatenate an argv array into a string.
argv | argv array |
sep | arg separator |
Definition at line 269 of file argv.c.
References stpcpy(), and xmalloc().
Referenced by getOutputFrom().
void argvPrint | ( | const char * | msg, |
ARGV_t | argv, | ||
FILE * | fp | ||
) |
Print argv array elements.
msg | output message prefix (or NULL) |
argv | argv array |
fp | output file handle (NULL uses stderr) |
Definition at line 14 of file argv.c.
Referenced by main(), rpmrepoGetFileList(), rpmsqlNew(), and rpmtsFini().
Find an element in an argv array.
argv | argv array |
val | string to find |
compar | strcmp-like comparison function, or NULL for argvCmp() |
Definition at line 141 of file argv.c.
References argvCmp(), and argvCount().
Referenced by findPreambleTag(), isPart(), nwlookupTag(), rpmfcClassify(), rpmfcSaveArg(), and wnlookupTag().
Sort an argv array.
argv | argv array |
compar | strcmp-like comparison function, or NULL for argvCmp() |
Definition at line 132 of file argv.c.
References argvCmp(), and argvCount().
Referenced by main(), nwlookupTag(), rpmfcSaveArg(), tagLoadATags(), and wnlookupTag().
int argvSplit | ( | ARGV_t * | argvp, |
const char * | str, | ||
const char * | seps | ||
) |
Split a string into an argv array.
*argvp | argv array |
str | string arg to split |
seps | separator characters (NULL is C isspace() chars) |
Definition at line 228 of file argv.c.
References _free(), argvFree(), xmalloc(), and xstrdup().
Referenced by _RequestPass(), formatValue(), getMachineInfo(), parsePrep(), processPackageFiles(), processSourceFiles(), rpmcliInstallElementPath(), rpmdbURIPath(), rpmfcHelper(), rpmtsOpenSDB(), rpmtsSkipFiles(), rpmvtNew(), tagLoadATags(), and unsatisfiedDepend().
Compare argv elements using strcasecmp (qsort/bsearch).
a | 1st instance address |
b | 2nd instance address |
Definition at line 97 of file argv.c.
References xstrcasecmp().
Referenced by findPreambleTag(), and isPart().