aboutsummaryrefslogtreecommitdiff
path: root/flx/input_fs.h
blob: a1594cf3bb83dce48b1d5c5ddc2f5eb327fe3759 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#ifndef __INPUT_FS_H__
#define __INPUT_FS_H__

#include "utils.h"
#include "flx.h"
#include "flx_fcntl.h"

typedef struct s_fs_status t_fs_status;

struct s_fs_status {
    char         bpath[BUFFER_LENGTH];        /* current real path */ 
    char         cpath[BUFFER_LENGTH];        /* current path representation */
    off_t        off_dir;                     /* dir offset for backup/restore */
    int          status;                      /* action status */
    int          options;                     /* read or write options */
    void         *dirnames;                   /* stack for directory backup */
    dev_t        dev;                         /* base device number */
    int          depth;                       /* depth level */
};

extern int           input_fs_fcntl(t_fs_status *env, int cmd);

extern int           input_fs_read(t_fs_status *spec, t_ft *tree);
extern t_fs_status   *input_fs_open(char *desc, char *opts);
extern t_fs_status   *input_fs_close(t_fs_status *spec);

#endif /* __INPUT_FS_H__ */