system.h File Reference

#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_mntentgetmntent (FILE *filep)

Variables

int errno
const char * program_name


Detailed Description

Definition in file system.h.


Define Documentation

#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(), copyNextLine(), 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(), 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   ) 

Definition at line 441 of file system.h.

Referenced by main(), and rpmcliInit().

#define dgettext ( DomainName,
Text   )     Text

Definition at line 446 of file system.h.

#define dirent   direct

Definition at line 175 of file system.h.

Referenced by ftpOpendir(), and fts_build().

#define EXIT_FAILURE   1

Definition at line 150 of file system.h.

Referenced by argerror(), getOutputFrom(), luaD_throw(), main(), poptGetNextOpt(), rpmcliConfigured(), rpmcliInit(), rpmReSign(), uncompressbuf(), unwrap(), vmefail(), and vrpmlog().

#define F_OK   0

Definition at line 165 of file system.h.

Referenced by db3open(), and rpmQueryVerify().

#define fgetfilecon ( _fd,
_c   )     (-1)

Definition at line 274 of file system.h.

#define FILE_RCSID ( id   ) 

Value:

static inline const char *rcsid(const char *p) { \
        return rcsid(p = id); \
}

Definition at line 629 of file system.h.

#define freecon ( _c   ) 

Definition at line 270 of file system.h.

Referenced by genCpioListAndHeader(), rpmfiBuildFSContexts(), and rpmfiBuildREContexts().

#define fsetfilecon ( _fd,
_c   )     (-1)

Definition at line 278 of file system.h.

#define getfilecon ( _fn,
_c   )     (-1)

Definition at line 272 of file system.h.

#define GETMNTENT_ONE   1

Definition at line 610 of file system.h.

#define GETMNTENT_TWO   0

Definition at line 611 of file system.h.

 
#define is_selinux_enabled (  )     (-1)

Definition at line 282 of file system.h.

Referenced by rpmtsCreate().

#define lchown   chown

Definition at line 573 of file system.h.

Referenced by fsmStage().

#define lgetfilecon ( _fn,
_c   )     (-1)

Definition at line 273 of file system.h.

Referenced by rpmfiBuildFSContexts().

#define lsetfilecon ( _fn,
_c   )     (-1)

Definition at line 277 of file system.h.

Referenced by fsmStage().

#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))

Definition at line 83 of file system.h.

Referenced by cpioHeaderRead().

#define minor ( dev   )     ((dev) & 0xff)

Definition at line 82 of file system.h.

Referenced by cpioHeaderRead(), cpioHeaderWrite(), and file_fsmagic().

#define MOUNTED   "/etc/mnttab"

Definition at line 623 of file system.h.

#define N_ ( Text   )     Text

Definition at line 449 of file system.h.

Referenced by rpmProblemString().

#define NLENGTH ( direct   )     ((direct)->d_namlen)

Definition at line 176 of file system.h.

#define our_mntent   struct our_mntent

Definition at line 608 of file system.h.

#define R_OK   4

Definition at line 168 of file system.h.

#define rpm_execcon ( _v,
_fn,
_av,
_envp   )     (0)

Definition at line 284 of file system.h.

#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)

Definition at line 537 of file system.h.

Referenced by fsmStage(), rpmPermsString(), and whatis().

#define security_check_context ( _c   )     (0)

Definition at line 280 of file system.h.

Referenced by rpmsxParse().

#define SEEK_CUR   1

Definition at line 161 of file system.h.

Referenced by rpmSingleHeaderFromFD().

#define SEEK_END   2

Definition at line 162 of file system.h.

Referenced by poptReadConfigFile().

#define SEEK_SET   0

Definition at line 160 of file system.h.

Referenced by apprentice_compile(), file_pipe2file(), readRPM(), uncompressbuf(), and writeRPM().

#define setfilecon ( _fn,
_c   )     (-1)

Definition at line 276 of file system.h.

#define setlocale ( Category,
Locale   ) 

Definition at line 433 of file system.h.

Referenced by main(), rpmcliInit(), and rpmGlob().

#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   ) 

Definition at line 443 of file system.h.

Referenced by main(), and rpmcliInit().

#define W_OK   2

Definition at line 167 of file system.h.

Referenced by db3open(), and rpmMkdirPath().

#define X_OK   1

Definition at line 166 of file system.h.

Referenced by findProgramPath().


Typedef Documentation

typedef char* security_context_t

Definition at line 268 of file system.h.


Function Documentation

char* alloca (  ) 

Referenced by argvSplit(), build(), buildForTarget(), configLine(), dateToTimet(), db3open(), doLookup(), doReadRC(), ensureOlder(), execCommand(), findEntry(), findProgramPath(), findTag(), fpsCompare(), fsmStage(), ftpCommand(), ftpLogin(), ftpReq(), ftsStashLatest(), getTagVal(), headerCheck(), headerMatchLocale(), httpReq(), lookupPackage(), main(), makeGPGSignature(), makePGPSignature(), markReplacedFiles(), parseForAttr(), parseForConfig(), parseForDev(), parseForLang(), parseForVerify(), poptGetNextOpt(), poptParseArgvString(), poptReadConfigFile(), poptReadDefaultConfig(), 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(), findProgramPath(), headerFindI18NString(), main(), and poptReadDefaultConfig().

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(), 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(), pgpHexSet(), pgpPrtSig(), pgpPrtUserID(), printNewSpecfile(), processSourceFiles(), queryArgCallback(), readIcon(), readLine(), realDateFormat(), relocateFileList(), rpmcliImportPubkey(), rpmdsDup(), rpmdsDupArgv(), rpmdsMerge(), rpmdsNew(), rpmdsNewDNEVR(), rpmdsSingle(), rpmdsThis(), rpmfd_Fopen(), rpmfiBuildFClasses(), rpmfiBuildFContexts(), rpmfiBuildFDeps(), rpmfiBuildFSContexts(), rpmfiBuildREContexts(), rpmfiFN(), rpmfiNew(), rpmGlob(), rpmInstallSourcePackage(), rpmProblemString(), rpmReadHeader(), rpmReadSignature(), rpmsxAdd(), rpmsxParse(), rpmsxSort(), rpmtsGetKeys(), rpmtsRun(), shescapeFormat(), showQueryPackage(), splitString(), triggercondsTag(), triggertypeTag(), urlFind(), valueMakeInteger(), valueMakeString(), verifyRSASignature(), vfs_parse_ls_lga(), vrpmlog(), xmlFormat(), and XurlNew().

void* xrealloc ( void *  ptr,
size_t  size 
)

Todo:
Annotate ptr with returned/out.

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(), readLine(), 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(), findProgramPath(), 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(), poptAddItem(), poptGetNextOpt(), poptSetExecPath(), printNewSpecfile(), processPackageFiles(), processSourceFiles(), rdToken(), readLine(), realDateFormat(), 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().


Variable Documentation

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(), poptGetNextOpt(), poptReadConfigFile(), 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

Definition at line 2 of file rpmqv.c.


Generated on Tue Jan 15 19:55:52 2008 for rpm by  doxygen 1.5.4