rpcsx/orbis-kernel/src/sys/sys_pipe.cpp

14 lines
382 B
C++
Raw Normal View History

2023-07-03 13:10:16 +02:00
#include "sys/sysproto.hpp"
2023-10-31 23:58:03 +01:00
#include "utils/Logs.hpp"
#include <pipe.hpp>
2023-07-03 13:10:16 +02:00
orbis::SysResult orbis::sys_pipe(Thread *thread) {
auto pipe = createPipe();
2023-10-31 23:58:03 +01:00
auto fd0 = thread->tproc->fileDescriptors.insert(pipe);
auto fd1 = thread->tproc->fileDescriptors.insert(pipe);
ORBIS_LOG_ERROR(__FUNCTION__, fd0, fd1);
thread->retval[0] = fd0;
thread->retval[1] = fd1;
return {};
}