diff options
author | Benji Dial <benji6283@gmail.com> | 2021-03-11 22:00:22 -0500 |
---|---|---|
committer | Benji Dial <benji6283@gmail.com> | 2021-03-11 22:00:22 -0500 |
commit | 5fcf57739e68a8b5053e03778aaee0eed445babd (patch) | |
tree | e7a8bab18668d112e58b1b48190195035c71fa8a /src/user/include/knob | |
parent | 0f2398d1f622cce37925f52d978d92e6cce1c7a9 (diff) | |
download | portland-os-5fcf57739e68a8b5053e03778aaee0eed445babd.tar.gz |
settings editor, and lots of changes in service of that
Diffstat (limited to 'src/user/include/knob')
-rw-r--r-- | src/user/include/knob/file.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/user/include/knob/file.h b/src/user/include/knob/file.h index d283288..04fc201 100644 --- a/src/user/include/knob/file.h +++ b/src/user/include/knob/file.h @@ -1,6 +1,10 @@ #ifndef KNOB_FILE_H #define KNOB_FILE_H +#ifdef __cplusplus +extern "C" { +#endif + #include <stdint.h> #include <pland/syscall.h> @@ -18,10 +22,15 @@ uint32_t read_line_from_file(struct file *f, char *sz, uint32_t max_length); uint32_t seek_file_to(struct file *f, uint32_t to); int32_t seek_file_by(struct file *f, int32_t by); +uint32_t get_file_pos(struct file *f) __attribute__ ((pure)); uint32_t file_size(struct file *f) __attribute__ ((pure)); void trunc_file(struct file *f); //return value must be manually freed, unless it is a null pointer _dir_info_entry_t *get_directory_info(const char *path, uint32_t *count_out); +#ifdef __cplusplus +} +#endif + #endif
\ No newline at end of file |