aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2026-02-02 15:53:01 +0000
committerRon Yorston <rmy@pobox.com>2026-02-02 15:53:01 +0000
commit8e6a6312552343aec7f5cde795ef0a11ef83b8ff (patch)
treea79bdb0b79518ae065bc762f06f28d9eb742d5f6 /include
parent74ee6e70c9a4f7822e7461069579c4e6ef0a2f04 (diff)
downloadbusybox-w32-8e6a6312552343aec7f5cde795ef0a11ef83b8ff.tar.gz
busybox-w32-8e6a6312552343aec7f5cde795ef0a11ef83b8ff.tar.bz2
busybox-w32-8e6a6312552343aec7f5cde795ef0a11ef83b8ff.zip
win32: add support for /dev/std{in,out,err}
Allow applets to open the "files" /dev/stdin, /dev/stdout and /dev/stderr. The 'stat' and 'ls' applets pretend they exist. Adds 48-56 bytes.
Diffstat (limited to 'include')
-rw-r--r--include/mingw.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/include/mingw.h b/include/mingw.h
index 1dcaabbe1..93b57ea29 100644
--- a/include/mingw.h
+++ b/include/mingw.h
@@ -514,8 +514,12 @@ int fsync(int fd);
514int kill(pid_t pid, int sig); 514int kill(pid_t pid, int sig);
515int link(const char *oldpath, const char *newpath); 515int link(const char *oldpath, const char *newpath);
516NOIMPL(mknod,const char *name UNUSED_PARAM, mode_t mode UNUSED_PARAM, dev_t device UNUSED_PARAM); 516NOIMPL(mknod,const char *name UNUSED_PARAM, mode_t mode UNUSED_PARAM, dev_t device UNUSED_PARAM);
517/* order of devices must match that in get_dev_type */ 517/* Order of devices must match that in get_dev_type and stdin,
518enum {DEV_NULL, DEV_TTY, DEV_ZERO, DEV_URANDOM, NOT_DEVICE = -1}; 518 * stdout and stderr must match their file descriptors. */
519enum {
520 DEV_STDIN, DEV_STDOUT, DEV_STDERR, DEV_NULL, DEV_TTY,
521 DEV_ZERO, DEV_URANDOM, NOT_DEVICE = -1
522};
519int get_dev_type(const char *filename); 523int get_dev_type(const char *filename);
520void update_special_fd(int dev, int fd); 524void update_special_fd(int dev, int fd);
521int mingw_open (const char *filename, int oflags, ...); 525int mingw_open (const char *filename, int oflags, ...);