mirror of
https://git.planet-casio.com/Lephenixnoir/gint.git
synced 2024-12-28 04:23:36 +01:00
fs: take const descriptor in open_generic()
This commit is contained in:
parent
5ff6a518f6
commit
b2b1f00d04
2 changed files with 3 additions and 3 deletions
|
@ -78,7 +78,7 @@ void fs_free_descriptor(int fd);
|
|||
exact file descriptor reuse_fd is used. (This is useful to reopen standard
|
||||
streams.) In this case, the only possible return values are -1 and reuse_fd
|
||||
itself. */
|
||||
int open_generic(fs_descriptor_type_t *type, void *data, int reuse_fd);
|
||||
int open_generic(fs_descriptor_type_t const *type, void *data, int reuse_fd);
|
||||
|
||||
/* fs_path_normalize(): Normalize a path to eliminate ., .. and redundant /
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ void fs_free_descriptor(int fd)
|
|||
fdtable[fd].data = NULL;
|
||||
}
|
||||
|
||||
int open_generic(fs_descriptor_type_t *type, void *data, int fd)
|
||||
int open_generic(fs_descriptor_type_t const *type, void *data, int fd)
|
||||
{
|
||||
if(!fdtable) {
|
||||
errno = ENOMEM;
|
||||
|
@ -79,7 +79,7 @@ int open_generic(fs_descriptor_type_t *type, void *data, int fd)
|
|||
|
||||
/* Standard streams */
|
||||
|
||||
static fs_descriptor_type_t devnull = {
|
||||
static fs_descriptor_type_t const devnull = {
|
||||
.read = NULL,
|
||||
.write = NULL,
|
||||
.lseek = NULL,
|
||||
|
|
Loading…
Reference in a new issue