#include <sys/types.h>
#include <sys/stat.h>
#include <stdio.h>
#include <time.h>
#include <strings.h>
#include <errno.h>
#include <sys/file.h>
#include <ctype.h>
Go to the source code of this file.
Data Structures | |
struct | our_mntent |
Defines | |
#define | major(dev) (((dev) >> 8) & 0xff) |
#define | minor(dev) ((dev) & 0xff) |
#define | makedev(maj, min) (((maj) << 8) | (min)) |
#define | EXIT_FAILURE 1 |
#define | SEEK_SET 0 |
#define | SEEK_CUR 1 |
#define | SEEK_END 2 |
#define | F_OK 0 |
#define | X_OK 1 |
#define | W_OK 2 |
#define | R_OK 4 |
#define | dirent direct |
#define | NLENGTH(direct) ((direct)->d_namlen) |
#define | freecon(_c) |
#define | getfilecon(_fn, _c) (-1) |
#define | lgetfilecon(_fn, _c) (-1) |
#define | fgetfilecon(_fd, _c) (-1) |
#define | setfilecon(_fn, _c) (-1) |
#define | lsetfilecon(_fn, _c) (-1) |
#define | fsetfilecon(_fd, _c) (-1) |
#define | security_check_context(_c) (0) |
#define | is_selinux_enabled() (-1) |
#define | rpm_execcon(_v, _fn, _av, _envp) (0) |
#define | __progname program_name |
#define | setprogname(pn) |
#define | setlocale(Category, Locale) |
#define | bindtextdomain(Domain, Directory) |
#define | textdomain(Domain) |
#define | _(Text) Text |
#define | dgettext(DomainName, Text) Text |
#define | N_(Text) Text |
#define | S_IFSOCK (0xc000) |
#define | S_ISLNK(mode) ((mode & 0xf000) == S_IFLNK) |
#define | S_ISSOCK(mode) ((mode & 0xf000) == S_IFSOCK) |
#define | lchown chown |
#define | our_mntent struct our_mntent |
#define | GETMNTENT_ONE 1 |
#define | GETMNTENT_TWO 0 |
#define | MOUNTED "/etc/mnttab" |
#define | FILE_RCSID(id) |
Typedefs | |
typedef char * | security_context_t |
Functions | |
char * | memchr () |
char * | stpcpy (char *dest, const char *src) |
char * | stpncpy (char *dest, const char *src, size_t n) |
char * | getenv (const char *name) |
char * | realpath (const char *path, char resolved_path[]) |
char * | alloca () |
void * | xmalloc (size_t size) |
void * | xcalloc (size_t nmemb, size_t size) |
void * | xrealloc (void *ptr, size_t size) |
char * | xstrdup (const char *str) |
void * | vmefail (size_t size) |
int | setenv (const char *name, const char *value, int replace) |
void | unsetenv (const char *name) |
struct our_mntent * | getmntent (FILE *filep) |
Variables | |
int | errno |
const char * | program_name |
Definition in file system.h.
#define _ | ( | Text | ) | Text |
Definition at line 444 of file system.h.
Referenced by addCanon(), addChangelog(), addDefault(), addFile(), addFileToTagAux(), addSource(), argerror(), armorFormat(), base64Format(), build(), buildArgCallback(), buildForTarget(), buildHost(), buildSpec(), checkForValidArchitectures(), checkOwners(), checkPassPhrase(), checkSpec(), copyFile(), copyNextLineFromOFI(), cpio_copy(), cpio_doio(), cpioStrerror(), cvtdberr(), dateFormat(), dayFormat(), db3close(), db3New(), db3open(), db_fini(), db_init(), depflagsFormat(), dnlInitIterator(), do_inject(), doAddSubtract(), doLogical(), doMultiplyDivide(), doPatch(), doPatchMacro(), doPrimary(), doReadRC(), doRelational(), doScript(), doSetupMacro(), doUntar(), fflagsFormat(), findPreambleTag(), formatValue(), fsmMapAttrs(), fsmStage(), ftpStrerror(), genCpioListAndHeader(), getGidS(), getGname(), getGnameS(), getOutputFrom(), getUidS(), getUname(), getUnameS(), handlePreambleTag(), headerCheck(), headerDump(), headerInject(), hexFormat(), IDTXglob(), installArgCallback(), isSpecFile(), machCompatCacheAdd(), main(), makeGPGSignature(), makePGPSignature(), makeTempFile(), manageFile(), miFreeHeader(), octalFormat(), packageBinaries(), parseBuildInstallClean(), parseDescription(), parseExpression(), parseExpressionBoolean(), parseExpressionString(), parseFiles(), parseFmt(), parseForAttr(), parseForConfig(), parseForDev(), parseForLang(), parseFormat(), parseForSimple(), parseForVerify(), parseNoSource(), parsePreamble(), parsePrep(), parseRCPOT(), parseScript(), parseSpec(), permsFormat(), pgpsigFormat(), printBanner(), printNewSpecfile(), printSize(), printVersion(), processBinaryFiles(), processPackageFiles(), processScriptFiles(), processSourceFiles(), psmWait(), queryHeader(), rdToken(), readFile(), readIcon(), readLead(), readLine(), readLineFromOFI(), readRPM(), realDateFormat(), relocateFileList(), rpmcliImportPubkeys(), rpmcliInit(), rpmcliSign(), rpmdbRebuild(), rpmdsCompare(), rpmdsNotify(), rpmdsProblem(), rpmDumpMacroTable(), rpmErase(), rpmfiDecideFate(), rpmGetPassPhrase(), rpmgiInitFilter(), rpmgiNext(), rpmgiOpen(), rpmGraph(), rpmInstall(), rpmInstallSource(), rpmInstallSourcePackage(), rpmlogMessage(), rpmMkdirPath(), rpmProblemString(), rpmQueryVerify(), rpmReadHeader(), rpmReadPackageFile(), rpmReadPackageManifest(), rpmReadSignature(), rpmReSign(), rpmRollback(), rpmShowProgress(), rpmspecQuery(), rpmsxParse(), rpmtsAddInstallElement(), rpmtsInitDSI(), rpmtsInitIterator(), rpmtsOpenDB(), rpmtsOpenSDB(), rpmtsOrder(), rpmtsRun(), rpmtsScoreFree(), rpmtsScoreGetEntry(), rpmtsScoreInit(), rpmtsSolve(), rpmVerifySignature(), rpmVerifySignatures(), rpmWriteSignature(), showQueryPackage(), singleSprintf(), skipFiles(), triggertypeFormat(), unsatisfiedDepend(), urlConnect(), urlFind(), urlFreeCache(), urlGetFile(), urlSplit(), verifyDependencies(), verifyDSASignature(), verifyHeader(), verifyMD5Signature(), verifyRSASignature(), verifySHA1Signature(), verifySizeSignature(), vmefail(), vrpmlog(), writeRPM(), xmlFormat(), and XurlFree().
#define __progname program_name |
Definition at line 410 of file system.h.
Referenced by argerror(), initTool(), main(), parseFmt(), and rpmcliInit().
#define bindtextdomain | ( | Domain, | |||
Directory | ) |
#define dirent direct |
#define EXIT_FAILURE 1 |
Definition at line 150 of file system.h.
Referenced by argerror(), getOutputFrom(), luaD_throw(), main(), rpmcliConfigured(), rpmcliInit(), rpmDigestDup(), rpmReSign(), uncompressbuf(), unwrap(), vmefail(), and vrpmlog().
#define FILE_RCSID | ( | id | ) |
#define freecon | ( | _c | ) |
#define is_selinux_enabled | ( | ) | (-1) |
#define lchown chown |
#define lgetfilecon | ( | _fn, | |||
_c | ) | (-1) |
#define lsetfilecon | ( | _fn, | |||
_c | ) | (-1) |
#define major | ( | dev | ) | (((dev) >> 8) & 0xff) |
Definition at line 81 of file system.h.
Referenced by cpioHeaderRead(), cpioHeaderWrite(), and file_fsmagic().
#define makedev | ( | maj, | |||
min | ) | (((maj) << 8) | (min)) |
#define minor | ( | dev | ) | ((dev) & 0xff) |
Definition at line 82 of file system.h.
Referenced by cpioHeaderRead(), cpioHeaderWrite(), and file_fsmagic().
#define N_ | ( | Text | ) | Text |
#define our_mntent struct our_mntent |
#define S_IFSOCK (0xc000) |
Definition at line 529 of file system.h.
Referenced by file_fsmagic(), rpmsxParse(), and vfs_parse_filetype().
#define S_ISLNK | ( | mode | ) | ((mode & 0xf000) == S_IFLNK) |
Definition at line 533 of file system.h.
Referenced by addFile(), fsmStage(), fts_stat(), genCpioListAndHeader(), makeTempFile(), printFileInfo(), rpmfcSYMLINK(), rpmPermsString(), rpmVerifyFile(), vfs_parse_ls_lga(), whatis(), and writeFile().
#define S_ISSOCK | ( | mode | ) | ((mode & 0xf000) == S_IFSOCK) |
#define security_check_context | ( | _c | ) | (0) |
#define SEEK_CUR 1 |
#define SEEK_SET 0 |
Definition at line 160 of file system.h.
Referenced by apprentice_compile(), file_pipe2file(), readRPM(), uncompressbuf(), and writeRPM().
#define setlocale | ( | Category, | |||
Locale | ) |
#define setprogname | ( | pn | ) |
Value:
{ if ((__progname = strrchr(pn, '/')) != NULL) __progname++; \ else __progname = pn; \ }
Definition at line 411 of file system.h.
Referenced by initTool(), main(), and rpmcliInit().
#define textdomain | ( | Domain | ) |
#define W_OK 2 |
typedef char* security_context_t |
char* alloca | ( | ) |
Referenced by argvSplit(), build(), buildForTarget(), dateToTimet(), db3open(), doLookup(), doReadRC(), ensureOlder(), findEntry(), findTag(), fpsCompare(), fsmStage(), ftpCommand(), ftpLogin(), ftpReq(), ftsStashLatest(), getTagVal(), headerCheck(), headerMatchLocale(), httpReq(), lookupPackage(), main(), makeGPGSignature(), makePGPSignature(), markReplacedFiles(), parseForAttr(), parseForConfig(), parseForDev(), parseForLang(), parseForVerify(), printFileInfo(), providePackageNVR(), relocateFileList(), rpmAddSignature(), rpmDetectPGPVersion(), rpmdsNVRMatchesDep(), rpmfiBuildFSContexts(), rpmfiBuildREContexts(), rpmGraph(), rpmInstall(), rpmlibNeedsFeature(), rpmReadPackageFile(), rpmReadSignature(), rpmsqExecve(), rpmteColorDS(), rpmts_Rollback(), rpmtsInitIterator(), rpmtsOrder(), rpmtsSetRootDir(), rpmvercmp(), rpmVerifyFile(), setPathDefault(), shescapeFormat(), skipFiles(), strntoul(), tagType(), unsatisfiedDepend(), urlFind(), verifyDependencies(), writeFile(), and xmlFormat().
char* getenv | ( | const char * | name | ) |
Referenced by dosetenv(), file_apprentice(), headerFindI18NString(), main(), and rpmGlob().
struct our_mntent* getmntent | ( | FILE * | filep | ) | [read] |
char* memchr | ( | ) |
char* realpath | ( | const char * | path, | |
char | resolved_path[] | |||
) |
Referenced by doLookup(), and rpmQueryVerify().
int setenv | ( | const char * | name, | |
const char * | value, | |||
int | replace | |||
) |
char* stpcpy | ( | char * | dest, | |
const char * | src | |||
) |
Referenced by addTE(), base64Format(), db3open(), doAddSubtract(), doPatch(), dosetenv(), doUntar(), ensureOlder(), findTag(), formatValue(), fpsCompare(), fsmFsPath(), fsmStage(), ftpCommand(), ftpOpendir(), ftpReq(), genCpioListAndHeader(), hGetNEVR(), hGetNEVRA(), initGlobs(), main(), makeGPGSignature(), makePGPSignature(), parseFmt(), pgpArmorWrap(), pgpsigFormat(), prDbiOpenFlags(), printNewSpecfile(), providePackageNVR(), relocateFileList(), rpmcliImportPubkey(), rpmDetectPGPVersion(), rpmdsDupArgv(), rpmdsNewDNEVR(), rpmdsNVRMatchesDep(), rpmdsThis(), rpmfcELF(), rpmfcSYMLINK(), rpmfiBuildFClasses(), rpmfiBuildFContexts(), rpmfiBuildFDeps(), rpmfiFN(), rpmfts_initialize(), rpmHeaderGetEntry(), rpmInstallSourcePackage(), rpmlibNeedsFeature(), rpmpsAppend(), rpmtsOrder(), rpmtsSetRootDir(), rpmVerifyFile(), rpmVerifySignatures(), showQueryPackage(), singleSprintf(), urlFind(), verifyDependencies(), verifyDSASignature(), verifyMD5Signature(), verifyRSASignature(), verifySHA1Signature(), verifySizeSignature(), writeFile(), xmlFormat(), and xmlstrcpy().
char* stpncpy | ( | char * | dest, | |
const char * | src, | |||
size_t | n | |||
) |
Referenced by doLookup(), ftpOpendir(), and rpmVerifySignatures().
void unsetenv | ( | const char * | name | ) |
Referenced by checkPassPhrase(), getOutputFrom(), makeGPGSignature(), makePGPSignature(), and open_dso().
void* vmefail | ( | size_t | size | ) |
Definition at line 13 of file rpmmalloc.c.
References _, and EXIT_FAILURE.
Referenced by xcalloc(), xmalloc(), xrealloc(), and xstrdup().
void* xcalloc | ( | size_t | nmemb, | |
size_t | size | |||
) |
Definition at line 34 of file rpmmalloc.c.
References vmefail().
Referenced by addTriggerIndex(), argiAdd(), checkResponse(), db3New(), defaultMachine(), dnlInitIterator(), fssizesTag(), ftpNLST(), ftpOpendir(), genCpioListAndHeader(), handleInstInstalledFiles(), headerGetLangs(), hGetNEVR(), hGetNEVRA(), htCreate(), IDTXnew(), initGlobs(), main(), mapInitIterator(), newFSM(), newItem(), newPackage(), newSpec(), newStringBuf(), parseFormat(), parseSpec(), pgpNewDig(), processSourceFiles(), rpmaviNew(), rpmDigestDup(), rpmDigestInit(), rpmdsDup(), rpmdsNew(), rpmdsSingle(), rpmdsThis(), rpmecNew(), rpmfcNew(), rpmfiNew(), rpmGetRpmlibProvides(), rpmgiNew(), rpmpsAppend(), rpmpsCreate(), rpmReadPackageManifest(), rpmsxNew(), rpmsxParse(), rpmteNew(), rpmteNewTSI(), rpmtsCreate(), rpmtsInitDSI(), rpmtsOrder(), rpmtsRun(), rpmtsScoreInit(), saveHardLink(), XfdNew(), xmlFormat(), and XrpmtsiInit().
void* xmalloc | ( | size_t | size | ) |
Definition at line 24 of file rpmmalloc.c.
References vmefail().
Referenced by addFile(), addSource(), addTE(), argvSplit(), base64Format(), bin2hex(), buildArgCallback(), convertAMD(), copyEntry(), cpioHeaderRead(), dbt2set(), depflagsFormat(), do_inject(), doAddSubtract(), doHeaderUnload(), doLookup(), doputenv(), doReadRC(), dosetenv(), expandMacroTable(), fflagsFormat(), formatValue(), fpCacheCreate(), fsmFsPath(), fsmStage(), genChangelog(), genCpioListAndHeader(), grabData(), headerCheck(), hexFormat(), htAddEntry(), htCreate(), machAddEquiv(), machCompatCacheAdd(), main(), makeGPGSignature(), makePGPSignature(), newOpenFileInfo(), newSl(), newSt(), newStringBuf(), octalFormat(), parseFmt(), parseForLang(), parseRCPOT(), permsFormat(), pgpArmorWrap(), pgpPrtSig(), pgpPrtUserID(), printNewSpecfile(), processSourceFiles(), queryArgCallback(), readIcon(), readLine(), realDateFormat(), relocateFileList(), rpmcliImportPubkey(), rpmDigestFinal(), rpmdsDup(), rpmdsDupArgv(), rpmdsMerge(), rpmdsNew(), rpmdsNewDNEVR(), rpmdsSingle(), rpmdsThis(), rpmfd_Fopen(), rpmfiBuildFClasses(), rpmfiBuildFContexts(), rpmfiBuildFDeps(), rpmfiBuildFSContexts(), rpmfiBuildREContexts(), rpmfiFN(), rpmfiNew(), rpmGlob(), rpmInstallSourcePackage(), rpmioMkpath(), rpmProblemString(), rpmReadHeader(), rpmReadSignature(), rpmsxAdd(), rpmsxParse(), rpmsxSort(), rpmtsGetKeys(), rpmtsRun(), shescapeFormat(), showQueryPackage(), splitString(), triggercondsTag(), triggertypeTag(), urlFind(), valueMakeInteger(), valueMakeString(), vfs_parse_ls_lga(), vrpmlog(), xmlFormat(), and XurlNew().
void* xrealloc | ( | void * | ptr, | |
size_t | size | |||
) |
Definition at line 45 of file rpmmalloc.c.
References vmefail().
Referenced by addCanon(), addDefault(), addFile(), appendStringBufAux(), argiAdd(), argvAdd(), argvAppend(), buildArgCallback(), currentDirectory(), expandMacroTable(), ftpNLST(), ftsStashLatest(), gidToGname(), gnameToGid(), handleInstInstalledFiles(), hsaReserve(), htAddEntry(), IDTXgrow(), installArgCallback(), machAddEquiv(), machCompatCacheAdd(), main(), parseForLang(), PBM_REALLOC(), pgpsigFormat(), queryArgCallback(), readLineFromOFI(), relocateFileList(), removePackage(), rpmfcExpandAppend(), rpmfiBuildFSContexts(), rpmfiBuildREContexts(), rpmfiNew(), rpmGlob(), rpmGraph(), rpmInstall(), rpmPlatform(), rpmpsAppend(), rpmsxAdd(), rpmtsAddInstallElement(), rpmtsAvailable(), rpmtsSolve(), rpmtsStashKeyid(), showQueryPackage(), stashSt(), triggercondsTag(), uidToUname(), unameToUid(), urlFind(), and vrpmlog().
char* xstrdup | ( | const char * | str | ) |
Definition at line 55 of file rpmmalloc.c.
References vmefail().
Referenced by addCanon(), addDefault(), addFile(), addSource(), addTE(), addTriggerIndex(), argvAdd(), argvAppend(), argvSplit(), armorFormat(), base64Format(), buildArgCallback(), convertAMD(), cpio_doio(), db3New(), depflagsFormat(), doLookup(), doSetupMacro(), dupAttrRec(), fflagsFormat(), forceIncludeFile(), formatValue(), fsmStage(), ftsStashLatest(), genSourceRpmName(), getGidS(), getGname(), getGnameS(), getUidS(), getUname(), getUnameS(), headerCheck(), hexFormat(), installArgCallback(), instprefixTag(), machAddEquiv(), machCompatCacheAdd(), main(), octalFormat(), parseExpressionBoolean(), parseExpressionString(), parseForSimple(), parseScript(), parseSpec(), permsFormat(), pgpsigFormat(), printNewSpecfile(), processPackageFiles(), processSourceFiles(), rdToken(), readLineFromOFI(), realDateFormat(), rpmcliAllArgCallback(), rpmcliQuery(), rpmds_compare(), rpmds_iternext(), rpmds_Single(), rpmdsCompare(), rpmdsFilter(), rpmfcELF(), rpmfd_Fopen(), rpmfi_BN(), rpmfi_DN(), rpmfi_FClass(), rpmfi_FGroup(), rpmfi_FLink(), rpmfi_FN(), rpmfi_FUser(), rpmfi_MD5(), rpmfi_subscript(), rpmfiNew(), rpmgiInitFilter(), rpmgiNext(), rpmGlob(), rpmInstall(), rpmInstallSourcePackage(), rpmPermsString(), rpmPlatform(), rpmpsAppend(), rpmQueryVerify(), rpmReadHeader(), rpmReadSignature(), rpmtsFindPubkey(), rpmtsScoreInit(), rpmtsSetCurrDir(), rpmtsSetRootDir(), stashSt(), triggercondsTag(), triggertypeFormat(), triggertypeTag(), urlFind(), urlSplit(), writeRPM(), and xmlFormat().
int errno |
Referenced by apprentice_compile(), apprentice_file(), apprentice_map(), checkOwners(), checkPassPhrase(), cpioStrerror(), currentDirectory(), doScript(), doUntar(), fdFgets(), fdReadable(), fdstat_exit(), fdWritable(), file_fsmagic(), file_pipe2file(), fsmStage(), ftpLogin(), ftpReq(), fts_build(), Fts_close(), Fts_read(), fts_safe_changedir(), fts_stat(), getHostAddress(), getOutputFrom(), httpReq(), main(), makeGPGSignature(), makePGPSignature(), makeTempFile(), mergesort(), mget(), packageBinaries(), processSourceFiles(), readLead(), rpmgiLoadReadHeader(), rpmioSlurp(), rpmMkdirPath(), rpmQueryVerify(), rpmsqAction(), rpmsqExecve(), rpmsxParse(), sigchld_cancel(), sread(), swrite(), tcpConnect(), ufdRead(), ufdWrite(), uncompressbuf(), unwrap(), urlStrerror(), and verifyHeader().
const char* program_name |