2023-10-31 12:22:22 +01:00
|
|
|
#include "KernelContext.hpp"
|
2023-07-03 13:10:16 +02:00
|
|
|
#include "sys/sysproto.hpp"
|
2023-10-31 12:22:22 +01:00
|
|
|
#include <cstdlib>
|
|
|
|
|
#include <unistd.h>
|
2023-07-03 13:10:16 +02:00
|
|
|
|
|
|
|
|
orbis::SysResult orbis::sys_fork(Thread *thread) { return ErrorCode::NOSYS; }
|
2023-07-06 18:16:25 +02:00
|
|
|
orbis::SysResult orbis::sys_pdfork(Thread *thread, ptr<sint> fdp, sint flags) {
|
|
|
|
|
return ErrorCode::NOSYS;
|
|
|
|
|
}
|
2023-10-31 12:22:22 +01:00
|
|
|
|
2023-07-03 13:10:16 +02:00
|
|
|
orbis::SysResult orbis::sys_vfork(Thread *thread) { return ErrorCode::NOSYS; }
|
2023-07-06 18:16:25 +02:00
|
|
|
orbis::SysResult orbis::sys_rfork(Thread *thread, sint flags) {
|
2023-10-31 19:28:40 +01:00
|
|
|
if (auto fork = thread->tproc->ops->fork) {
|
|
|
|
|
return fork(thread, flags);
|
2023-10-31 12:22:22 +01:00
|
|
|
}
|
2023-10-31 19:28:40 +01:00
|
|
|
return ErrorCode::NOSYS;
|
2023-07-06 18:16:25 +02:00
|
|
|
}
|