|
|
@@ -513,6 +513,7 @@ int lfs_removeattr(lfs_t *lfs, const char *path, uint8_t type);
|
|
|
|
|
|
/// File operations ///
|
|
|
|
|
|
+#ifndef LFS_NO_MALLOC
|
|
|
// Open a file
|
|
|
//
|
|
|
// The mode that the file is opened in is determined by the flags, which
|
|
|
@@ -522,6 +523,10 @@ int lfs_removeattr(lfs_t *lfs, const char *path, uint8_t type);
|
|
|
int lfs_file_open(lfs_t *lfs, lfs_file_t *file,
|
|
|
const char *path, int flags);
|
|
|
|
|
|
+// if LFS_NO_MALLOC is defined, lfs_file_open() will fail with LFS_ERR_NOMEM
|
|
|
+// thus use lfs_file_opencfg() with config.buffer set.
|
|
|
+#endif
|
|
|
+
|
|
|
// Open a file with extra configuration
|
|
|
//
|
|
|
// The mode that the file is opened in is determined by the flags, which
|