X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/d60418a05f2cbaa97140c569ba63f1a1eb831a79..49dc1d0a9eafdb1e369ead88c3c8882bc6959a17:/client/loclass/fileutils.h diff --git a/client/loclass/fileutils.h b/client/loclass/fileutils.h index 623190a6..f18472ab 100644 --- a/client/loclass/fileutils.h +++ b/client/loclass/fileutils.h @@ -38,6 +38,9 @@ #ifndef FILEUTILS_H #define FILEUTILS_H + +#ifndef ON_DEVICE + /** * @brief Utility function to save data to a file. This method takes a preferred name, but if that * file already exists, it tries with another name until it finds something suitable. @@ -49,7 +52,17 @@ * @return 0 for ok, 1 for failz */ int saveFile(const char *preferredName, const char *suffix, const void* data, size_t datalen); +/** + * @brief Utility function to save load binary data from a a file. This method takes a filename, + * Should only be used for fixed-size binary files + * @param fileName the name of the file + * @param data a buffer to place data in + * @param datalen the length of the data/data. + * @return + */ +int fileExists(const char *filename); +#endif //ON_DEVICE /** * Utility function to print to console. This is used consistently within the library instead @@ -59,5 +72,4 @@ int saveFile(const char *preferredName, const char *suffix, const void* data, si * @param fmt */ void prnlog(char *fmt, ...); -int fileExists(const char *filename); #endif // FILEUTILS_H