From cb3d049badb772fc1ea7051540d50c89f73e36dd Mon Sep 17 00:00:00 2001 From: James M Snell Date: Wed, 23 May 2018 15:04:23 -0700 Subject: src: refactor bootstrap to use bootstrap object MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PR-URL: https://github.com/nodejs/node/pull/20917 Reviewed-By: Gus Caplan Reviewed-By: Michaƫl Zasso Reviewed-By: Ruben Bridgewater Reviewed-By: Ben Noordhuis Reviewed-By: Joyee Cheung Reviewed-By: Refael Ackermann --- src/node_internals.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'src/node_internals.h') diff --git a/src/node_internals.h b/src/node_internals.h index 1ba56458b1..3014a0e5f7 100644 --- a/src/node_internals.h +++ b/src/node_internals.h @@ -357,6 +357,8 @@ inline v8::Local FillGlobalStatsArray(Environment* env, return node::FillStatsArray(env->fs_stats_field_array(), s, offset); } +void SetupBootstrapObject(Environment* env, + v8::Local bootstrapper); void SetupProcessObject(Environment* env, int argc, const char* const* argv, @@ -873,6 +875,24 @@ static inline const char *errno_string(int errorno) { TRACING_CATEGORY_NODE "." #one "," \ TRACING_CATEGORY_NODE "." #one "." #two +// Functions defined in node.cc that are exposed via the bootstrapper object + +void Chdir(const v8::FunctionCallbackInfo& args); +void CPUUsage(const v8::FunctionCallbackInfo& args); +void Hrtime(const v8::FunctionCallbackInfo& args); +void MemoryUsage(const v8::FunctionCallbackInfo& args); +void RawDebug(const v8::FunctionCallbackInfo& args); +void Umask(const v8::FunctionCallbackInfo& args); + +#if defined(__POSIX__) && !defined(__ANDROID__) && !defined(__CloudABI__) +void SetGid(const v8::FunctionCallbackInfo& args); +void SetEGid(const v8::FunctionCallbackInfo& args); +void SetUid(const v8::FunctionCallbackInfo& args); +void SetEUid(const v8::FunctionCallbackInfo& args); +void SetGroups(const v8::FunctionCallbackInfo& args); +void InitGroups(const v8::FunctionCallbackInfo& args); +#endif // __POSIX__ && !defined(__ANDROID__) && !defined(__CloudABI__) + } // namespace node void napi_module_register_by_symbol(v8::Local exports, -- cgit v1.2.3