Hi guys,
I want a plugin to create a file (in the same directory) or if it allready exists to change it.
Think these are the functions i could use. But I am not sure how to use them.
int (*open_utf8)(const char* pathname, int flags);
int (*open)(const char* pathname, int flags, ...);
int (*close)(int fd);
int (*creat)(const char *pathname, mode_t mode);
int (*fdprintf)(int fd, const char *fmt, ...) ATTRIBUTE_PRINTF(2, 3);
int (*read_line)(int fd, char* buffer, int buffer_size);
For example I don't know what flags I could pass to (*open). Or what is this , mode_t mode?
Maybe someone could explain at a little example to open a file and write something to it? Would be nice