Main Page   Modules   Data Structures   File List   Data Fields   Globals   Related Pages  

lib/misc.h

Go to the documentation of this file.
00001 #ifndef H_MISC
00002 #define H_MISC
00003 
00009 #ifdef __cplusplus
00010 extern "C" {
00011 #endif
00012 
00020 rpmRC rpmMkdirPath (const char * dpath, const char * dname)
00021         /*@globals fileSystem, internalState @*/
00022         /*@modifies fileSystem, internalState @*/;
00023 
00031 /*@only@*/ char ** splitString(const char * str, int length, char sep)
00032         /*@*/;
00033 
00038 void freeSplitString( /*@only@*/ char ** list)
00039         /*@modifies list @*/;
00040 
00047 /*@unused@*/ static inline
00048 /*@only@*/ char * stripTrailingChar(/*@only@*/ char * s, char c)
00049         /*@modifies *s */
00050 {
00051     char * t;
00052 /*@-boundswrite@*/
00053     for (t = s + strlen(s) - 1; *t == c && t >= s; t--)
00054         *t = '\0';
00055 /*@=boundswrite@*/
00056     return s;
00057 }
00058 
00066 int dosetenv(const char * name, const char * value, int overwrite)
00067         /*@globals environ@*/
00068         /*@modifies *environ @*/;
00069 
00075 int doputenv(const char * str)
00076         /*@globals environ@*/
00077         /*@modifies *environ @*/;
00078 
00092 int makeTempFile(/*@null@*/ const char * prefix,
00093                 /*@null@*/ /*@out@*/ const char ** fnptr,
00094                 /*@out@*/ FD_t * fdptr)
00095         /*@globals rpmGlobalMacroContext,
00096                 fileSystem, internalState @*/
00097         /*@modifies *fnptr, *fdptr, rpmGlobalMacroContext,
00098                 fileSystem, internalState @*/;
00099 
00104 /*@only@*/ char * currentDirectory(void)
00105         /*@*/;
00106 
00109 /*@-exportlocal@*/
00110 int myGlobPatternP (const char *patternURL)     /*@*/;
00111 /*@=exportlocal@*/
00112 
00115 int rpmGlob(const char * patterns, /*@out@*/ int * argcPtr,
00116                 /*@out@*/ const char *** argvPtr)
00117         /*@globals fileSystem@*/
00118         /*@modifies *argcPtr, *argvPtr, fileSystem @*/;
00119 
00120 #ifdef __cplusplus
00121 }
00122 #endif
00123 
00124 #endif  /* H_MISC */

Generated on Sun Oct 26 13:01:59 2003 for rpm by doxygen1.2.18