From eb7b832d47bcbd74181028c62e871d407ba63a23 Mon Sep 17 00:00:00 2001 From: Alexis211 Date: Sun, 18 Oct 2009 17:50:02 +0200 Subject: More work on syscalls --- Source/Kernel/SyscallManager/Res.ns.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Source/Kernel/SyscallManager') diff --git a/Source/Kernel/SyscallManager/Res.ns.cpp b/Source/Kernel/SyscallManager/Res.ns.cpp index aceadf7..274f6f1 100644 --- a/Source/Kernel/SyscallManager/Res.ns.cpp +++ b/Source/Kernel/SyscallManager/Res.ns.cpp @@ -1,6 +1,8 @@ #include "Res.ns.h" #include +#include +#include #include namespace Res { @@ -42,6 +44,8 @@ void unregisterRes(u32int id) { u32int call(u32int ressource, u8int wat, u32int a, u32int b, u32int c, u32int d, u32int e) { if (ressource == 0xFFFFFE) { //TODO : return ressource id for some stuff for current process if (a == VT_IFACE_OBJTYPE) return Task::currProcess()->getVirtualTerminal()->resId(); + if (a == PR_IFACE_OBJTYPE) return Task::currProcess()->resId(); + if (a == TH_IFACE_OBJTYPE) return Task::currThread()->resId(); return 0; } else { if (ressource > size or ressources[ressource] == 0) { -- cgit v1.2.3