blob: e442fe22f77d848b8bfd21e53cd4675fe448ad1a [file] [log] [blame]
yuezonghe824eb0c2024-06-27 02:32:26 -07001/*
2 * mkfifoat() for uClibc
3 *
4 * Copyright (C) 2009 Analog Devices Inc.
5 *
6 * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
7 */
8
9#include <sys/syscall.h>
10#include <sys/stat.h>
11
12#ifdef __NR_mknodat
13int mkfifoat(int fd, const char *path, mode_t mode)
14{
15 return mknodat(fd, path, mode | S_IFIFO, 0);
16}
17#else
18/* should add emulation with mkfifo() and /proc/self/fd/ ... */
19#endif