mirror of
https://github.com/vivier/EMILE.git
synced 2024-12-21 18:30:20 +00:00
Add open, read, close, lseek, fstat
This commit is contained in:
parent
fed542e8ad
commit
c864f078d7
@ -17,13 +17,11 @@ struct emile_block {
|
||||
} __attribute__((packed));
|
||||
|
||||
struct emile_container {
|
||||
u_int16_t unit_id;
|
||||
u_int32_t size;
|
||||
struct emile_block blocks[0];
|
||||
} __attribute__((packed));
|
||||
|
||||
typedef struct {
|
||||
unsigned long size;
|
||||
unsigned long offset;
|
||||
device_io_t device;
|
||||
struct emile_container* container;
|
||||
@ -32,4 +30,11 @@ typedef struct {
|
||||
unsigned long current_block;
|
||||
char *buffer[0];
|
||||
} container_FILE;
|
||||
|
||||
extern container_FILE *container_open(device_io_t *device, char *current);
|
||||
extern int container_close(container_FILE *file);
|
||||
extern int container_lseek(container_FILE *file, off_t offset, int whence);
|
||||
extern ssize_t container_read(container_FILE *file, void *ptr, size_t size);
|
||||
extern int container_fstat(container_FILE *file, struct stream_stat *buf);
|
||||
|
||||
#endif /* _LIBCONTAINER_H_ */
|
||||
|
Loading…
Reference in New Issue
Block a user