libctru v2.5.0
Loading...
Searching...
No Matches
gdbhio.h
Go to the documentation of this file.
1/**
2 * @file gdbhio.h
3 * @brief Luma3DS GDB HIO (called File I/O in GDB documentation) functions.
4 */
5
6#pragma once
7
8#include <fcntl.h>
9#include <sys/time.h>
10#include <sys/stat.h>
11
12#define GDBHIO_STDIN_FILENO 0
13#define GDBHIO_STDOUT_FILENO 1
14#define GDBHIO_STDERR_FILENO 2
15
16int gdbHioOpen(const char *pathname, int flags, mode_t mode);
17int gdbHioClose(int fd);
18int gdbHioRead(int fd, void *buf, unsigned int count);
19int gdbHioWrite(int fd, const void *buf, unsigned int count);
20off_t gdbHioLseek(int fd, off_t offset, int flag);
21int gdbHioRename(const char *oldpath, const char *newpath);
22int gdbHioUnlink(const char *pathname);
23int gdbHioStat(const char *pathname, struct stat *st);
24int gdbHioFstat(int fd, struct stat *st);
25int gdbHioGettimeofday(struct timeval *tv, void *tz);
26int gdbHioIsatty(int fd);
27
28///< Host I/O 'system' function, requires 'set remote system-call-allowed 1'.
29int gdbHioSystem(const char *command);
int gdbHioIsatty(int fd)
Host I/O 'system' function, requires 'set remote system-call-allowed 1'.