diff --git a/src/fs/file.c b/src/fs/file.c index 4137d6b..ac7a3fa 100644 --- a/src/fs/file.c +++ b/src/fs/file.c @@ -113,7 +113,6 @@ void process_fci(const file_t *pe, int fmd) { } } -#define MAX_DYNAMIC_FILES 128 uint16_t dynamic_files = 0; file_t dynamic_file[MAX_DYNAMIC_FILES]; diff --git a/src/fs/file.h b/src/fs/file.h index 072786f..1758cbe 100644 --- a/src/fs/file.h +++ b/src/fs/file.h @@ -69,15 +69,17 @@ #define MAX_DEPTH 4 +#define MAX_DYNAMIC_FILES 256 + typedef struct file { - const uint16_t fid; - const uint8_t parent; //entry number in the whole table!! const uint8_t *name; + uint8_t *data; //should include 2 bytes len at begining + const uint16_t fid; + const uint8_t acl[7]; + const uint8_t parent; //entry number in the whole table!! const uint8_t type; const uint8_t ef_structure; - uint8_t *data; //should include 2 bytes len at begining - const uint8_t acl[7]; -} file_t; +} __attribute__ ((packed)) file_t; extern bool file_has_data(file_t *);