فهرست منبع

Kernel: Make sys$anon_create() require the "stdio" promise if pledged

Andreas Kling 4 سال پیش
والد
کامیت
7899e14e72
1فایلهای تغییر یافته به همراه2 افزوده شده و 0 حذف شده
  1. 2 0
      Kernel/Syscalls/anon_create.cpp

+ 2 - 0
Kernel/Syscalls/anon_create.cpp

@@ -33,6 +33,8 @@ namespace Kernel {
 
 
 int Process::sys$anon_create(size_t size, int options)
 int Process::sys$anon_create(size_t size, int options)
 {
 {
+    REQUIRE_PROMISE(stdio);
+
     if (size % PAGE_SIZE)
     if (size % PAGE_SIZE)
         return -EINVAL;
         return -EINVAL;