瀏覽代碼

LibCore: Put safe_syscall() debug spam behind #ifdef

Andreas Kling 5 年之前
父節點
當前提交
32dfde746a
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      Libraries/LibCore/SyscallUtils.h

+ 2 - 0
Libraries/LibCore/SyscallUtils.h

@@ -41,8 +41,10 @@ inline int safe_syscall(Syscall syscall, Args&&... args)
     for (;;) {
         int sysret = syscall(forward<Args>(args)...);
         if (sysret == -1) {
+#ifdef SAFE_SYSCALL_DEBUG
             int saved_errno = errno;
             dbg() << "Core::safe_syscall: " << sysret << " (" << saved_errno << ": " << strerror(saved_errno) << ")";
+#endif
             if (errno == EINTR)
                 continue;
             ASSERT_NOT_REACHED();