12 #ifndef LLVM_FUZZER_IO_H
13 #define LLVM_FUZZER_IO_H
19 long GetEpoch(
const std::string &Path);
22 bool ExitOnError =
true);
31 long *Epoch,
size_t MaxSize,
bool ExitOnError);
35 const std::string &FileName);
38 std::string
DirName(
const std::string &FileName);
47 void Printf(
const char *Fmt, ...);
50 bool IsFile(
const std::string &Path);
53 std::vector<std::string> *V,
bool TopDir);
67 #endif // LLVM_FUZZER_IO_H
int DuplicateFile(int Fd)
void ListFilesInDirRecursive(const std::string &Dir, long *Epoch, std::vector< std::string > *V, bool TopDir)
bool IsFile(const std::string &Path)
std::string FileToString(const std::string &Path)
void ReadDirToVectorOfUnits(const char *Path, std::vector< Unit > *V, long *Epoch, size_t MaxSize, bool ExitOnError)
long GetEpoch(const std::string &Path)
void Printf(const char *Fmt,...)
FILE * OpenFile(int Fd, const char *Mode)
std::string DirPlusFile(const std::string &DirPath, const std::string &FileName)
void CopyFileToErr(const std::string &Path)
void WriteToFile(const Unit &U, const std::string &Path)
Unit FileToVector(const std::string &Path, size_t MaxSize, bool ExitOnError)
void RemoveFile(const std::string &Path)
std::vector< uint8_t > Unit
std::string DirName(const std::string &FileName)